X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=servers%2Fslapd%2Fback-bdb%2Ferror.c;h=388e78b869c4a974869bd3216080fb21b215a585;hb=202080dfa1c69002fca45f960cfcf69dd1541f98;hp=cbb457929a0eee08b9f29b3664185572aee67217;hpb=d611a4b49a00238ed32ae84c68f27c6a0ef2273a;p=openldap diff --git a/servers/slapd/back-bdb/error.c b/servers/slapd/back-bdb/error.c index cbb457929a..388e78b869 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-2007 The OpenLDAP Foundation. * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -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( const DB_ENV *env, const char *pfx, const char * msg ) +#endif { #ifdef HAVE_EBCDIC if ( msg[0] > 0x7f ) @@ -31,6 +35,17 @@ void bdb_errcall( const char *pfx, char * msg ) 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 #undef db_strerror