OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Michael Schloh
Root: /e/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-web, openpkg-src Date: 14-Oct-2002 21:40:33
Branch: HEAD Handle: 2002101420403101
Modified files:
openpkg-src/inn inn-db4.patch inn.spec
openpkg-web news.txt
Log:
Reduced patch code to minimum, using no transaction contexts.
Summary:
Revision Changes Path
1.2 +28 -82 openpkg-src/inn/inn-db4.patch
1.47 +1 -1 openpkg-src/inn/inn.spec
1.1788 +1 -0 openpkg-web/news.txt
____________________________________________________________________________
Index: openpkg-src/inn/inn-db4.patch
============================================================
$ cvs diff -u -r1.1 -r1.2 inn-db4.patch
--- openpkg-src/inn/inn-db4.patch 10 Oct 2002 14:24:00 -0000 1.1
+++ openpkg-src/inn/inn-db4.patch 14 Oct 2002 19:40:32 -0000 1.2
@@ -1,6 +1,6 @@
diff -Naur inn-2.3.3.orig/storage/ovdb/ovdb.c inn-2.3.3/storage/ovdb/ovdb.c
---- inn-2.3.3.orig/storage/ovdb/ovdb.c Thu Oct 10 14:29:29 2002
-+++ inn-2.3.3/storage/ovdb/ovdb.c Thu Oct 10 16:15:55 2002
+--- inn-2.3.3.orig/storage/ovdb/ovdb.c Mon May 6 08:02:07 2002
++++ inn-2.3.3/storage/ovdb/ovdb.c Mon Oct 14 21:37:07 2002
@@ -99,7 +99,7 @@
#error Need BerkeleyDB 2.6.x, 2.7.x, or 3.x
#endif
@@ -10,28 +10,13 @@
#error Need BerkeleyDB 2.6.x, 2.7.x, or 3.x
#endif
#endif
-@@ -382,6 +382,9 @@
- static int open_db_file(int which)
- {
- int ret;
-+#if DB_VERSION_MAJOR == 4
-+ DB_TXN *txnp = NULL;
-+#endif
-
- if(dbs[which] != NULL)
- return 0;
-@@ -401,13 +404,28 @@
+@@ -401,13 +401,23 @@
if(ovdb_conf.pagesize > 0)
(dbs[which])->set_pagesize(dbs[which], ovdb_conf.pagesize);
-+#if DB_VERSION_MAJOR == 4
-+/* starting sometime early db 4.X, db->open gets a new parameter txnp */
-+ if (ret = OVDBenv->txn_begin(OVDBenv, NULL, &txnp, 0)) {
-+ (dbs[which])->close(dbs[which], 0);
-+ dbs[which] = NULL;
-+ return ret;
-+ }
-+ if(ret = (dbs[which])->open(dbs[which], txnp, _dbnames[which], NULL,
++#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MAJOR >= 1)
++/* starting sometime early db 4.X, db->open gets a new parameter */
++ if(ret = (dbs[which])->open(dbs[which], 0, _dbnames[which], NULL,
+ DB_BTREE, _db_flags, 0666)) {
+ (dbs[which])->close(dbs[which], 0);
+ dbs[which] = NULL;
@@ -39,19 +24,18 @@
+ }
+#else
if(ret = (dbs[which])->open(dbs[which], _dbnames[which], NULL, DB_BTREE,
-- _db_flags, 0666)) {
-+ _db_flags, 0666)) {
+ _db_flags, 0666)) {
(dbs[which])->close(dbs[which], 0);
dbs[which] = NULL;
return ret;
}
-#endif
-+#endif /* #if DB_VERSION_MAJOR == 4 */
++#endif /* #if DB_VERSION_MAJOR >= 4 */
+#endif /* #if DB_VERSION_MAJOR == 2 */
return 0;
}
-@@ -590,7 +608,7 @@
+@@ -590,7 +600,7 @@
return TRUE;
}
@@ -60,16 +44,7 @@
static int upgrade_database(char *name)
{
int ret;
-@@ -636,6 +654,8 @@
- DB *vdb;
- #if DB_VERSION_MAJOR == 2
- DB_INFO dbinfo;
-+#elif DB_VERSION_MAJOR == 4
-+ DB_TXN *txnp = NULL;
- #endif
- DBT key, val;
-
-@@ -659,7 +679,7 @@
+@@ -659,7 +669,7 @@
if(flags & OVDB_RECOVER)
ai_flags |= DB_RECOVER;
@@ -78,12 +53,12 @@
if(ovdb_conf.txn_nosync)
ai_flags |= DB_TXN_NOSYNC;
#endif
-@@ -697,12 +717,12 @@
+@@ -697,12 +707,12 @@
OVDBenv->set_errcall(OVDBenv, OVDBerror);
OVDBenv->set_cachesize(OVDBenv, 0, ovdb_conf.cachesize, 1);
-#if DB_VERSION_MINOR >= 2
-+#if (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR >= 2) || DB_VERSION_MAJOR == 4
++#if (DB_VERSION_MAJOR == 3 && DB_VERSION_MINOR >= 2) || DB_VERSION_MAJOR >= 4
if(ovdb_conf.txn_nosync)
OVDBenv->set_flags(OVDBenv, DB_TXN_NOSYNC, 1);
#endif
@@ -93,20 +68,15 @@
if(ret = OVDBenv->open(OVDBenv, ovdb_conf.home, NULL, ai_flags, 0666)) {
#else
if(ret = OVDBenv->open(OVDBenv, ovdb_conf.home, ai_flags, 0666)) {
-@@ -726,12 +746,27 @@
+@@ -726,12 +736,22 @@
syslog(L_FATAL, "OVDB: open: db_create: %s", db_strerror(ret));
return ret;
}
- if(ret = vdb->open(vdb, "version", NULL, DB_BTREE,
+
-+#if DB_VERSION_MAJOR == 4
-+/* starting sometime early db 4.X, db->open gets a new parameter txnp */
-+ if (ret = OVDBenv->txn_begin(OVDBenv, NULL, &txnp, 0)) {
-+ vdb->close(vdb, 0);
-+ vdb = NULL;
-+ return ret;
-+ }
-+ if(ret = vdb->open(vdb, txnp, "version", NULL, DB_BTREE,
++#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MAJOR >= 1)
++/* starting sometime early db 4.X, db->open gets a new parameter */
++ if(ret = vdb->open(vdb, 0, "version", NULL, DB_BTREE,
_db_flags, 0666)) {
vdb->close(vdb, 0);
syslog(L_FATAL, "OVDB: open: version->open: %s", db_strerror(ret));
@@ -118,32 +88,18 @@
+ syslog(L_FATAL, "OVDB: open: version->open: %s", db_strerror(ret));
+ return ret;
+ }
-+#endif /* DB_VERSION_MAJOR == 4 */
++#endif /* DB_VERSION_MAJOR >= 4 */
#endif /* DB_VERSION_MAJOR == 2 */
memset(&key, 0, sizeof key);
-@@ -779,6 +814,8 @@
-
- #if DB_VERSION_MAJOR == 2
- DB_INFO dbinfo;
-+#elif DB_VERSION_MAJOR == 4
-+ DB_TXN *txnp = NULL;
- #endif
-
- if(OVDBenv != NULL) {
-@@ -841,33 +878,77 @@
+@@ -841,33 +861,62 @@
syslog(L_FATAL, "OVDB: open: db_create: %s", db_strerror(ret));
return FALSE;
}
+
-+#if DB_VERSION_MAJOR == 4
-+/* starting sometime early db 4.X, db->open gets a new parameter txnp */
-+ if (ret = OVDBenv->txn_begin(OVDBenv, NULL, &txnp, 0)) {
-+ groupstats->close(groupstats, 0);
-+ groupstats = NULL;
-+ return ret;
-+ }
-+ if(ret = groupstats->open(groupstats, txnp, "groupstats", NULL,
++#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MAJOR >= 1)
++/* starting sometime early db 4.X, db->open gets a new parameter */
++ if(ret = groupstats->open(groupstats, 0, "groupstats", NULL,
+ DB_BTREE, _db_flags, 0666)) {
+ groupstats->close(groupstats, 0);
+ syslog(L_FATAL, "OVDB: open: groupstats->open: %s", db_strerror(ret));
@@ -156,18 +112,13 @@
syslog(L_FATAL, "OVDB: open: groupstats->open: %s", db_strerror(ret));
return FALSE;
}
-+#endif /* #if DB_VERSION_MAJOR == 4 */
++#endif /* #if DB_VERSION_MAJOR >= 4 */
if(ret = db_create(&groupsbyname, OVDBenv, 0)) {
syslog(L_FATAL, "OVDB: open: db_create: %s", db_strerror(ret));
return FALSE;
}
-+#if DB_VERSION_MAJOR == 4
-+ if (ret = OVDBenv->txn_begin(OVDBenv, NULL, &txnp, 0)) {
-+ groupsbyname->close(groupsbyname, 0);
-+ groupsbyname = NULL;
-+ return ret;
-+ }
-+ if(ret = groupsbyname->open(groupsbyname, txnp, "groupsbyname", NULL, DB_HASH,
++#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MAJOR >= 1)
++ if(ret = groupsbyname->open(groupsbyname, 0, "groupsbyname", NULL, DB_HASH,
+ _db_flags, 0666)) {
+ groupsbyname->close(groupsbyname, 0);
+ syslog(L_FATAL, "OVDB: open: groupsbyname->open: %s", db_strerror(ret));
@@ -180,18 +131,13 @@
syslog(L_FATAL, "OVDB: open: groupsbyname->open: %s", db_strerror(ret));
return FALSE;
}
-+#endif /* #if DB_VERSION_MAJOR == 4 */
++#endif /* #if DB_VERSION_MAJOR >= 4 */
if(ret = db_create(&groupaliases, OVDBenv, 0)) {
syslog(L_FATAL, "OVDB: open: db_create: %s", db_strerror(ret));
return FALSE;
}
-+#if DB_VERSION_MAJOR == 4
-+ if (ret = OVDBenv->txn_begin(OVDBenv, NULL, &txnp, 0)) {
-+ groupaliases->close(groupaliases, 0);
-+ groupaliases = NULL;
-+ return ret;
-+ }
-+ if(ret = groupaliases->open(groupaliases, txnp, "groupaliases", NULL, DB_HASH,
++#if (DB_VERSION_MAJOR >= 4 && DB_VERSION_MAJOR >= 1)
++ if(ret = groupaliases->open(groupaliases, 0, "groupaliases", NULL, DB_HASH,
+ _db_flags, 0666)) {
+ groupaliases->close(groupaliases, 0);
+ syslog(L_FATAL, "OVDB: open: groupaliases->open: %s", db_strerror(ret));
@@ -205,7 +151,7 @@
return FALSE;
}
-#endif
-+#endif /* #if DB_VERSION_MAJOR == 4 */
++#endif /* #if DB_VERSION_MAJOR >= 4 */
+#endif /* #if DB_VERSION_MAJOR == 2 */
Cutofflow = FALSE;
Index: openpkg-src/inn/inn.spec
============================================================
$ cvs diff -u -r1.46 -r1.47 inn.spec
--- openpkg-src/inn/inn.spec 10 Oct 2002 14:24:00 -0000 1.46
+++ openpkg-src/inn/inn.spec 14 Oct 2002 19:40:32 -0000 1.47
@@ -37,7 +37,7 @@
Group: News
License: ISC
Version: %{V_inn}
-Release: 20021010
+Release: 20021014
# list of sources
Source0: ftp://ftp.isc.org/isc/inn/inn-%{V_inn}.tar.gz
Index: openpkg-web/news.txt
============================================================
$ cvs diff -u -r1.1787 -r1.1788 news.txt
--- openpkg-web/news.txt 14 Oct 2002 19:11:07 -0000 1.1787
+++ openpkg-web/news.txt 14 Oct 2002 19:40:31 -0000 1.1788
@@ -1,3 +1,4 @@
+14-Oct-2002: Upgraded package: P<inn-2.3.3-20021014>
14-Oct-2002: Upgraded package: P<exim-4.10-20021014>
14-Oct-2002: Upgraded package: P<imagemagick-5.5.1.0-20021014>
14-Oct-2002: Upgraded package: P<sasl-2.1.9-20021014>
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [EMAIL PROTECTED]