From: Howard Chu Date: Mon, 15 Oct 2007 10:22:51 +0000 (+0000) Subject: Fix error message propagation X-Git-Tag: OPENLDAP_REL_ENG_2_4_9~20^2~510 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=e63ac9ac9e78c14ac46e981ac7c3da02c2d75e04;p=openldap Fix error message propagation --- diff --git a/servers/slapd/back-bdb/config.c b/servers/slapd/back-bdb/config.c index c1a29e527e..32291d7d05 100644 --- a/servers/slapd/back-bdb/config.c +++ b/servers/slapd/back-bdb/config.c @@ -633,8 +633,9 @@ bdb_cf_gen( ConfigArgs *c ) } ch_free( testpath ); if ( !f ) { - snprintf( c->cr_msg, sizeof( c->cr_msg ), "invalid path: %s", strerror( errno )); - Debug( LDAP_DEBUG_ANY, "%s: %s\n", c->log, c->cr_msg, 0 ); + snprintf( c->cr_msg, sizeof( c->cr_msg ), "%s: invalid path: %s", + c->log, strerror( errno )); + Debug( LDAP_DEBUG_ANY, "%s\n", c->cr_msg, 0, 0 ); return -1; } diff --git a/servers/slapd/bconfig.c b/servers/slapd/bconfig.c index dd9ac913b7..5aa496f74d 100644 --- a/servers/slapd/bconfig.c +++ b/servers/slapd/bconfig.c @@ -4826,6 +4826,7 @@ config_modify_internal( CfEntryInfo *ce, Operation *op, SlapReply *rs, out: /* Undo for a failed operation */ if ( rc != LDAP_SUCCESS ) { + ConfigReply msg = ca->reply; for ( s = save_attrs; s; s = s->a_next ) { if ( s->a_flags & SLAP_ATTR_IXDEL ) { s->a_flags &= ~(SLAP_ATTR_IXDEL|SLAP_ATTR_IXADD); @@ -4862,6 +4863,7 @@ out: } } } + ca->reply = msg; } if ( ca->cleanup )