From: Howard Chu Date: Thu, 16 Dec 2004 13:48:36 +0000 (+0000) Subject: ITS#3443 fix shutdown test X-Git-Tag: OPENLDAP_REL_ENG_2_3_0ALPHA~43 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8d4281d84312140ef8b65d3c228298725fb62060;p=openldap ITS#3443 fix shutdown test --- diff --git a/servers/slapd/syncrepl.c b/servers/slapd/syncrepl.c index f8b7e55fc5..8e15a43934 100644 --- a/servers/slapd/syncrepl.c +++ b/servers/slapd/syncrepl.c @@ -912,11 +912,13 @@ do_syncrepl( return NULL; } - if ( slapd_shutdown && si->si_ld ) { - ldap_get_option( si->si_ld, LDAP_OPT_DESC, &s ); - connection_client_stop( s ); - ldap_unbind( si->si_ld ); - si->si_ld = NULL; + if ( slapd_shutdown ) { + if ( si->si_ld ) { + ldap_get_option( si->si_ld, LDAP_OPT_DESC, &s ); + connection_client_stop( s ); + ldap_unbind( si->si_ld ); + si->si_ld = NULL; + } return NULL; }