head 1.2; access; symbols OPENPKG_E1_MP_HEAD:1.2 OPENPKG_E1_MP:1.2 OPENPKG_E1_MP_2_STABLE:1.2 OPENPKG_E1_FP:1.2 OPENPKG_2_STABLE_20061018:1.2 OPENPKG_2_STABLE:1.2.0.14 OPENPKG_2_STABLE_BP:1.2 OPENPKG_2_5_SOLID:1.2.0.12 OPENPKG_2_5_SOLID_BP:1.2 OPENPKG_2_4_RELEASE:1.2 OPENPKG_2_4_SOLID:1.2.0.10 OPENPKG_2_4_SOLID_BP:1.2 OPENPKG_2_3_RELEASE:1.2 OPENPKG_2_3_SOLID:1.2.0.8 OPENPKG_2_3_SOLID_BP:1.2 OPENPKG_2_2_RELEASE:1.2 OPENPKG_2_2_SOLID:1.2.0.6 OPENPKG_2_2_SOLID_BP:1.2 OPENPKG_2_1_RELEASE:1.2 OPENPKG_2_1_SOLID:1.2.0.4 OPENPKG_2_1_SOLID_BP:1.2 OPENPKG_2_0_RELEASE:1.2 OPENPKG_2_0_SOLID:1.2.0.2 OPENPKG_2_0_SOLID_BP:1.2; locks; strict; comment @# @; 1.2 date 2002.11.14.08.22.37; author rse; state dead; branches; next 1.1; 1.1 date 2002.10.16.16.14.51; author ms; state Exp; branches; next ; desc @@ 1.2 log @upgrade to 2.1.10 fix now includes DB 4.1 patch @ text @diff -Naur cyrus-imapd-2.1.9.orig/lib/cyrusdb_db3.c cyrus-imapd-2.1.9/lib/cyrusdb_db3.c --- cyrus-imapd-2.1.9.orig/lib/cyrusdb_db3.c Tue Aug 6 18:55:03 2002 +++ cyrus-imapd-2.1.9/lib/cyrusdb_db3.c Wed Oct 16 18:11:24 2002 @@@@ -228,10 +228,15 @@@@ static int mysync(void) { +#if (DB_VERSION_MAJOR <= 4 && DB_VERSION_MINOR < 1) int r; +#endif assert(dbinit); +#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MINOR >= 1) + txn_checkpoint(dbenv, 0, 0, 0); +#else do { #if (DB_VERSION_MAJOR > 3) || ((DB_VERSION_MAJOR == 3) && (DB_VERSION_MINOR > 0)) r = txn_checkpoint(dbenv, 0, 0, 0); @@@@ -244,6 +249,7 @@@@ db_strerror(r)); return CYRUSDB_IOERROR; } +#endif return 0; } @@@@ -347,7 +353,11 @@@@ } /* xxx set comparator! */ +#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MINOR >= 1) + r = db->open(db, NULL, fname, NULL, DB_BTREE, DB_CREATE, 0664); +#else r = db->open(db, fname, NULL, DB_BTREE, DB_CREATE, 0664); +#endif if (r != 0) { syslog(LOG_ERR, "DBERROR: opening %s: %s", fname, db_strerror(r)); return CYRUSDB_IOERROR; @ 1.1 log @Repair build to comply with the new Berkley db 4.1.24 API. @ text @@