From: Hallvard Furuseth Date: Mon, 11 Jul 2005 19:09:30 +0000 (+0000) Subject: retcode_op_func(): Fix uninitialized variable 'ref': X-Git-Tag: OPENLDAP_AC_BP~417 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=d5685734d2eb0e3520d58036a1ee793fce51af81;p=openldap retcode_op_func(): Fix uninitialized variable 'ref': Under rs->sr_err == LDAP_REFERRAL, return LDAP_OTHER "bad referral object" if both rdi->rdi_ref and default_referral are NULL. --- diff --git a/servers/slapd/overlays/retcode.c b/servers/slapd/overlays/retcode.c index 5c2320ee59..0efa850466 100644 --- a/servers/slapd/overlays/retcode.c +++ b/servers/slapd/overlays/retcode.c @@ -1,5 +1,5 @@ /* retcode.c - customizable response for client testing purposes */ -/* $Header$ */ +/* $OpenLDAP$ */ /* This work is part of OpenLDAP Software . * * Copyright 2005 The OpenLDAP Foundation. @@ -360,8 +360,7 @@ retcode_op_func( Operation *op, SlapReply *rs ) if ( rdi->rdi_ref != NULL ) { ref = rdi->rdi_ref; - - } else if ( default_referral != NULL ) { + } else { ref = default_referral; }