From: Paul Marquess Date: Mon, 23 Feb 1998 10:47:26 +0000 (+0000) Subject: Back out DB_File patch (change _553) and tweak Configure. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ee02776e1e319bf3f9a6f0b42762f94334cfa372;p=p5sagit%2Fp5-mst-13.2.git Back out DB_File patch (change _553) and tweak Configure. Subject: ANNOUNCE: perl5.004_60 is available p4raw-id: //depot/perl@578 --- diff --git a/Configure b/Configure index afba27c..e0dff4f 100755 --- a/Configure +++ b/Configure @@ -8561,6 +8561,7 @@ main() { #ifdef DB_VERSION_MAJOR /* DB version >= 2 */ int Major, Minor, Patch ; + unsigned long Version ; (void)db_version(&Major, &Minor, &Patch) ; printf("You have Berkeley DB Version 2 or greater\n"); @@ -8576,9 +8577,15 @@ main() } printf("db.h and libdb are compatible\n") ; - /* needs to be >= 2.05 */ - if (DB_VERSION_MAJOR == 2 && DB_VERSION_MINOR == 0 && DB_VERSION_PATCH < 5) { - printf("but Perl needs Berkeley DB 2.0.5 or greater\n") ; + + Version = DB_VERSION_MAJOR * 1000000 + DB_VERSION_MINOR * 1000 + + DB_VERSION_PATCH ; + + /* needs to be >= 2.3.4 */ + if (Version < 2003004) { + /* if (DB_VERSION_MAJOR == 2 && DB_VERSION_MINOR == 0 && DB_VERSION_PATCH +< 5) { */ + printf("but Perl needs Berkeley DB 2.3.4 or greater\n") ; exit(2); } diff --git a/ext/DB_File/DB_File.xs b/ext/DB_File/DB_File.xs index b6da386..91b4dc2 100644 --- a/ext/DB_File/DB_File.xs +++ b/ext/DB_File/DB_File.xs @@ -533,14 +533,6 @@ DB_File db ; DBT_flags(key) ; DBT_flags(value) ; RETVAL = do_SEQ(db, key, value, R_LAST) ; - if (RETVAL < 0 && errno == EBADF) - { - recno_t oops = -1; - key.data = &oops; - key.size = sizeof(oops); - db_get(db, key, value, 0); - RETVAL = do_SEQ(db, key, value, R_LAST) ; - } if (RETVAL == 0) RETVAL = *(I32 *)key.data ; else /* No key means empty file */