X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=servers%2Fslapd%2Fback-bdb%2Ferror.c;h=bb5eeb74d434ec4a4bc6ac07bdd974ef10d4dbd2;hb=a05cbba77a94875ac00c207344d819513ff6499d;hp=4b58c834c2cc9c21e318abf68ede21b8aa993ee8;hpb=3c598e89fb34a892d369a138daa8c3314294493c;p=openldap diff --git a/servers/slapd/back-bdb/error.c b/servers/slapd/back-bdb/error.c index 4b58c834c2..bb5eeb74d4 100644 --- a/servers/slapd/back-bdb/error.c +++ b/servers/slapd/back-bdb/error.c @@ -2,7 +2,7 @@ /* $OpenLDAP$ */ /* This work is part of OpenLDAP Software . * - * Copyright 2000-2004 The OpenLDAP Foundation. + * Copyright 2000-2011 The OpenLDAP Foundation. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -22,18 +22,29 @@ #include "slap.h" #include "back-bdb.h" +#if DB_VERSION_FULL < 0x04030000 void bdb_errcall( const char *pfx, char * msg ) +#else +void bdb_errcall( const DB_ENV *env, const char *pfx, const char * msg ) +#endif { #ifdef HAVE_EBCDIC if ( msg[0] > 0x7f ) __etoa( msg ); #endif -#ifdef NEW_LOGGING - LDAP_LOG ( OPERATION, INFO, "bdb(%s): %s\n", pfx, msg, 0 ); -#else Debug( LDAP_DEBUG_ANY, "bdb(%s): %s\n", pfx, msg, 0 ); +} + +#if DB_VERSION_FULL >= 0x04030000 +void bdb_msgcall( const DB_ENV *env, const char *msg ) +{ +#ifdef HAVE_EBCDIC + if ( msg[0] > 0x7f ) + __etoa( msg ); #endif + Debug( LDAP_DEBUG_TRACE, "bdb: %s\n", msg, 0, 0 ); } +#endif #ifdef HAVE_EBCDIC