]> git.sur5r.net Git - openldap/commitdiff
Fix ldap_start_tls_s, don't check for TLS present on a non-existent sockbuf
authorHoward Chu <hyc@openldap.org>
Sat, 12 Jan 2002 02:25:22 +0000 (02:25 +0000)
committerHoward Chu <hyc@openldap.org>
Sat, 12 Jan 2002 02:25:22 +0000 (02:25 +0000)
libraries/libldap/tls.c

index 31b2a3bc74e47fad70070b22f0faa3287e5ae779..4be0f16187dbcbe6d13ffc2f60ae801f37590de9 100644 (file)
@@ -1306,7 +1306,7 @@ ldap_start_tls_s ( LDAP *ld,
 
        /* XXYYZ: this initiates operation only on default connection! */
 
-       if ( ldap_pvt_tls_inplace( ld->ld_sb ) != 0 ) {
+       if ( ld->ld_sb != NULL && ldap_pvt_tls_inplace( ld->ld_sb ) != 0 ) {
                return LDAP_LOCAL_ERROR;
        }