#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 )
}
}
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;
*/
#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)