Package: openldap2 Severity: important Tags: patch Hello,
i encountered the bug described in ITS#3192 [1] resp. ITS#3250 [2]. The fix mentioned there worked for me. Greetz Florian [1] http://www.openldap.org/its/index.cgi/Software%20Bugs?id=3192 [2] http://www.openldap.org/its/index.cgi/Software%20Bugs?id=3250 --- Original Bugreport ITS#3250 --- Date: Tue, 20 Jul 2004 23:58:39 GMT From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: libldap/result.c changes for ITS #2982, not quite right Full_Name: Arlene Berry Version: 2.2.13, 2.1.29, 2.1.30 OS: RedHat 9 URL: ftp://ftp.openldap.org/incoming/ Submission from: (NULL) (64.221.115.99) I'm trying to use PADL's nss_ldap on RedHat 9 and Windows 2003 Active Directory with SFU 3.5 for the LDAP server. The problem is that when chasing referrals, which nss_ldap does, things hang for five minutes. I reproduced the problem with ldapsearch using the -C option. I tracked the problem down to the the changes made to libldap/result.c between versions 2.1.28 and 2.1.29 of OpenLDAP (ITS #2982). The problem is this code around line 305: for ( lc = ld->ld_conns; lc != NULL; lc = nextlc ) { nextlc = lc->lconn_next; if ( ber_sockbuf_ctrl( lc->lconn_sb, LBER_SB_OPT_DATA_READY, NULL ) ) { rc = try_read1msg( ld, msgid, all, lc->lconn_sb, &lc, result ); break; } } if ( lc == NULL ) { rc = ldap_int_select( ld, tvp ); ... When I turned on debugging I saw newer versions going into ldap_int_select() which older versions do not. The reason is that in the newer versions try_read1msg() may set lc to NULL which it didn't prior to this change. The result is it now enters the if statement which it didn't previously. I restored the old behavior by doing the following: int lc_found = 0; .... for ( lc = ld->ld_conns; lc != NULL; lc = nextlc ) { nextlc = lc->lconn_next; if ( ber_sockbuf_ctrl( lc->lconn_sb, LBER_SB_OPT_DATA_READY, NULL ) ) { rc = try_read1msg( ld, msgid, all, lc->lconn_sb, &lc, result ); lc_found = 1; break; } } if ( !lc_found ) { rc = ldap_int_select( ld, tvp ); ... This fixed the five minute hang. --- End Original Bugreport --- -- System Information: Debian Release: 3.1 Architecture: i386 (i686) Kernel: Linux 2.6.8-3-k7 Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]