]> git.sur5r.net Git - openldap/commitdiff
ld could be used after ldap_unbind_ext()
authorPierangelo Masarati <ando@openldap.org>
Sun, 18 Mar 2007 20:44:11 +0000 (20:44 +0000)
committerPierangelo Masarati <ando@openldap.org>
Sun, 18 Mar 2007 20:44:11 +0000 (20:44 +0000)
tests/progs/slapd-read.c
tests/progs/slapd-search.c

index c938875ec4c0fb7814560f9b015242620df84e01..dd5e692d07bbc64191b62d53d9cacc9f1c79e662 100644 (file)
@@ -343,6 +343,7 @@ retry:;
                                case LDAP_UNAVAILABLE:
                                        if ( do_retry > 0 ) {
                                                ldap_unbind_ext( ld, NULL, NULL );
+                                               ld = NULL;
                                                do_retry--;
                                                if ( delay != 0 ) {
                                                    sleep( delay );
index 7ad90d20e45661c1df123378297037cd2730faad..afda1768b5db7f9850129258178f042cadf49ead 100644 (file)
@@ -373,6 +373,7 @@ retry:;
                                case LDAP_UNAVAILABLE:
                                        if ( do_retry > 0 ) {
                                                ldap_unbind_ext( ld, NULL, NULL );
+                                               ld = NULL;
                                                do_retry--;
                                                if ( delay != 0 ) {
                                                    sleep( delay );