[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[jerenkrantz@apache.org: cvs commit: apr-util/dbm apr_dbm_berkeleydb.c]

From: Greg Stein <gstein_at_lyra.org>
Date: 2002-09-19 12:31:05 CEST

We may want to incorporate a similar fix into our DB code.

----- Forwarded message from jerenkrantz@apache.org -----

From: jerenkrantz@apache.org
Subject: cvs commit: apr-util/dbm apr_dbm_berkeleydb.c
To: apr-util-cvs@apache.org
Date: 19 Sep 2002 08:04:18 -0000
Reply-To: dev@apr.apache.org

jerenkrantz 2002/09/19 01:04:17

  Modified: . CHANGES
               dbm apr_dbm_berkeleydb.c
  Log:
  Fix so that we can use compile against db-4.1.24 which altered the open
  signature.
  
  Revision Changes Path
  1.80 +2 -0 apr-util/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/apr-util/CHANGES,v
  retrieving revision 1.79
  retrieving revision 1.80
  diff -u -u -r1.79 -r1.80
  --- CHANGES 19 Sep 2002 05:33:18 -0000 1.79
  +++ CHANGES 19 Sep 2002 08:04:17 -0000 1.80
  @@ -1,5 +1,7 @@
   Changes with APR-util 0.9.2
   
  + *) Add support for Berkeley DB 4.1. [Justin Erenkrantz]
  +
     *) Add --bindir option to apu-config. [Justin Erenkrantz]
   
   Changes with APR-util 0.9.1
  
  
  
  1.19 +10 -3 apr-util/dbm/apr_dbm_berkeleydb.c
  
  Index: apr_dbm_berkeleydb.c
  ===================================================================
  RCS file: /home/cvs/apr-util/dbm/apr_dbm_berkeleydb.c,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -u -r1.18 -r1.19
  --- apr_dbm_berkeleydb.c 13 Mar 2002 20:40:47 -0000 1.18
  +++ apr_dbm_berkeleydb.c 19 Sep 2002 08:04:17 -0000 1.19
  @@ -73,8 +73,11 @@
    */
   
   #if defined(DB_VERSION_MAJOR) && (DB_VERSION_MAJOR == 4)
  -/* At this time, there are no differences from our perspective between
  - * DB3 and DB4. */
  +/* DB 4.1 has an altered open() argument list. */
  +#if defined(DB_VERSION_MINOR) && (DB_VERSION_MINOR >= 1)
  +#define DB_NEED_OPEN_TXN_ARG
  +#endif
  +/* Otherwise, DB4 can be treated as DB3. */
   #define DB_VER 3
   #elif defined(DB_VERSION_MAJOR) && (DB_VERSION_MAJOR == 3)
   #define DB_VER 3
  @@ -195,7 +198,11 @@
   
   #if DB_VER == 3
           if ((dberr = db_create(&file.bdb, NULL, 0)) == 0) {
  - if ((dberr = (*file.bdb->open)(file.bdb, pathname, NULL,
  + if ((dberr = (*file.bdb->open)(file.bdb,
  +#ifdef DB_NEED_OPEN_TXN_ARG
  + NULL,
  +#endif
  + pathname, NULL,
                                              DB_HASH, dbmode,
                                              apr_posix_perms2mode(perm))) != 0) {
                   /* close the DB handler */
  
  
  

----- End forwarded message -----

-- 
Greg Stein, http://www.lyra.org/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Sep 19 12:31:15 2002

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.