From e524236afa638c8c39aebdb84488b08c9c6fc020 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Thu, 3 Jun 2010 07:03:05 +0000 Subject: Add Berkeley DB 5 support. (An outstanding issue with BDB 4.8 related to 51086 that also affects BDB 5 is not yet resolved) --- ext/dba/dba_db4.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ext/dba/dba_db4.c') diff --git a/ext/dba/dba_db4.c b/ext/dba/dba_db4.c index 22ca375900..dd2152f8b6 100644 --- a/ext/dba/dba_db4.c +++ b/ext/dba/dba_db4.c @@ -37,14 +37,14 @@ #endif static void php_dba_db4_errcall_fcn( -#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 3) +#if (DB_VERSION_MAJOR > 4 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 3)) const DB_ENV *dbenv, #endif const char *errpfx, const char *msg) { TSRMLS_FETCH(); -#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 8 && DB_VERSION_PATCH <= 26) +#if (DB_VERSION_MAJOR == 5 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR == 8)) /* Bug 51086, Berkeley DB 4.8.26 */ /* This code suppresses a BDB 4.8 error message that BDB incorrectly emits */ { @@ -124,7 +124,7 @@ DBA_OPEN_FUNC(db4) if ((err=db_create(&dbp, NULL, 0)) == 0) { dbp->set_errcall(dbp, php_dba_db4_errcall_fcn); if ( -#if (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 1) +#if (DB_VERSION_MAJOR > 4 || (DB_VERSION_MAJOR == 4 && DB_VERSION_MINOR >= 1)) (err=dbp->open(dbp, 0, info->path, NULL, type, gmode, filemode)) == 0) { #else (err=dbp->open(dbp, info->path, NULL, type, gmode, filemode)) == 0) { -- cgit v1.2.1