You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

27 lines
1.1 KiB

diff -Naur exim-4.10.orig/src/dbstuff.h exim-4.10/src/dbstuff.h
--- exim-4.10.orig/src/dbstuff.h Mon Jul 22 10:59:48 2002
+++ exim-4.10/src/dbstuff.h Mon Oct 14 21:03:33 2002
@@ -126,6 +126,15 @@
/* Access functions */
+#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MINOR >= 1)
+/* EXIM_DBOPEN - sets *dbpp to point to an EXIM_DB, NULL if failed */
+#define EXIM_DBOPEN(name, flags, mode, dbpp) \
+ if (db_create(dbpp, NULL, 0) != 0 || \
+ (*dbpp)->open(*dbpp, 0, CS name, NULL, \
+ ((flags) == O_RDONLY)? DB_UNKNOWN : DB_HASH, \
+ ((flags) == O_RDONLY)? DB_RDONLY : DB_CREATE, \
+ mode) != 0) *(dbpp) = NULL
+#else
/* EXIM_DBOPEN - sets *dbpp to point to an EXIM_DB, NULL if failed */
#define EXIM_DBOPEN(name, flags, mode, dbpp) \
if (db_create(dbpp, NULL, 0) != 0 || \
@@ -133,6 +142,7 @@
((flags) == O_RDONLY)? DB_UNKNOWN : DB_HASH, \
((flags) == O_RDONLY)? DB_RDONLY : DB_CREATE, \
mode) != 0) *(dbpp) = NULL
+#endif
/* EXIM_DBGET - returns TRUE if successful, FALSE otherwise */
#define EXIM_DBGET(db, key, data) \