mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-25 00:59:45 -05:00
BDB 4.3 compatibility
This commit is contained in:
parent
84ce549016
commit
e6a12272cc
3 changed files with 10 additions and 7 deletions
|
|
@ -22,7 +22,11 @@
|
|||
#include "slap.h"
|
||||
#include "back-bdb.h"
|
||||
|
||||
#if DB_VERSION_FULL < 0x04030000
|
||||
void bdb_errcall( const char *pfx, char * msg )
|
||||
#else
|
||||
void bdb_errcall( DB_ENV *env, const char *pfx, const char * msg )
|
||||
#endif
|
||||
{
|
||||
#ifdef HAVE_EBCDIC
|
||||
if ( msg[0] > 0x7f )
|
||||
|
|
|
|||
|
|
@ -724,14 +724,9 @@ bdb_idl_insert_key(
|
|||
}
|
||||
}
|
||||
if ( id < lo || id > hi ) {
|
||||
/* Delete the current lo/hi */
|
||||
rc = cursor->c_del( cursor, 0 );
|
||||
if ( rc != 0 ) {
|
||||
err = "c_del";
|
||||
goto fail;
|
||||
}
|
||||
/* Replace the current lo/hi */
|
||||
data.data = &id;
|
||||
rc = cursor->c_put( cursor, key, &data, DB_KEYFIRST );
|
||||
rc = cursor->c_put( cursor, key, &data, DB_CURRENT );
|
||||
if ( rc != 0 ) {
|
||||
err = "c_put lo/hi";
|
||||
goto fail;
|
||||
|
|
|
|||
|
|
@ -139,7 +139,11 @@ int bdb_fix_dn( Entry *e, int checkit );
|
|||
*/
|
||||
#define bdb_errcall BDB_SYMBOL(errcall)
|
||||
|
||||
#if DB_VERSION_FULL < 0x04030000
|
||||
void bdb_errcall( const char *pfx, char * msg );
|
||||
#else
|
||||
void bdb_errcall( DB_ENV *env, const char *pfx, const char * msg );
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_EBCDIC
|
||||
#define ebcdic_dberror BDB_SYMBOL(ebcdic_dberror)
|
||||
|
|
|
|||
Loading…
Reference in a new issue