#include <sys/types.h>
#include <errno.h>
#include <fcntl.h>
#include <stddef.h>
#include <stdio.h>
#include "../include/db.h"
Go to the source code of this file.
◆ DB_FLAGS
◆ USE_OPEN_FLAGS
Value:(O_CREAT | O_EXCL |
O_EXLOCK | O_NONBLOCK | O_RDONLY | \
Referenced by dbopen().
◆ __dbpanic()
void __dbpanic |
( |
DB * |
dbp | ) |
|
Definition at line 89 of file utils/db1-ast/db/db.c.
References __P().
Referenced by __bt_split().
93 dbp->del = (int (*)
__P((const struct
__db *,
94 const
DBT *, u_int))) __dberr;
95 dbp->get = (
int (*)
__P((const struct __db *,
96 const DBT *, DBT *, u_int))) __dberr;
97 dbp->put = (
int (*)
__P((const struct __db *,
98 DBT *, const DBT *, u_int))) __dberr;
99 dbp->
seq = (
int (*)
__P((const struct __db *,
100 DBT *, DBT *, u_int))) __dberr;
101 dbp->sync = (
int (*)
__P((const struct __db *, u_int))) __dberr;
102 dbp->
fd = (
int (*)
__P((const struct __db *))) __dberr;
static int __dberr __P((void))
static volatile unsigned int seq
◆ __P()
static int __dberr __P |
( |
(void) |
| ) |
|
|
static |
◆ dbopen()
DB* dbopen |
( |
char * |
fname, |
|
|
int |
flags, |
|
|
int |
mode, |
|
|
DBTYPE |
type, |
|
|
const void * |
openinfo |
|
) |
| const |
Definition at line 48 of file utils/db1-ast/db/db.c.
References __bt_open(), __hash_open(), __rec_open(), DB_BTREE, DB_FLAGS, DB_HASH, DB_RECNO, errno, NULL, type, and USE_OPEN_FLAGS.
Referenced by convert_bdb_to_sqlite3(), create_bdb_astdb(), and mssql_connect().
55 #define DB_FLAGS (DB_LOCK | DB_SHMEM | DB_TXN) 56 #define USE_OPEN_FLAGS \ 57 (O_CREAT | O_EXCL | O_EXLOCK | O_NONBLOCK | O_RDONLY | \ 58 O_RDWR | O_SHLOCK | O_TRUNC) 67 mode, openinfo, flags & DB_FLAGS));
69 return (
__rec_open(fname, flags & USE_OPEN_FLAGS,
70 mode, openinfo, flags & DB_FLAGS));
DB * __hash_open(char *file, int flags, int mode, const HASHINFO *info, int dflags) const
DB * __bt_open(char *fname, int flags, int mode, const BTREEINFO *openinfo, int dflags) const
DB * __rec_open(char *fname, int flags, int mode, const RECNOINFO *openinfo, int dflags) const