From f28f15da41e65a1cfcb02db3ea9510d50b9a4d7e Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Tue, 31 Aug 2004 02:08:28 +0000 Subject: [PATCH] Sync with HEAD --- libraries/libldap/result.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libraries/libldap/result.c b/libraries/libldap/result.c index dbf75ee140..03356c5cef 100644 --- a/libraries/libldap/result.c +++ b/libraries/libldap/result.c @@ -314,6 +314,7 @@ wait4msg( if( (*result = chkResponseList(ld, msgid, all)) != NULL ) { rc = (*result)->lm_msgtype; } else { + int lc_ready = 0; for ( lc = ld->ld_conns; lc != NULL; lc = nextlc ) { nextlc = lc->lconn_next; @@ -321,11 +322,12 @@ wait4msg( LBER_SB_OPT_DATA_READY, NULL ) ) { rc = try_read1msg( ld, msgid, all, lc->lconn_sb, &lc, result ); + lc_ready = 1; break; } } - if ( lc == NULL ) { + if ( !lc_ready ) { rc = ldap_int_select( ld, tvp ); #ifdef LDAP_DEBUG if ( rc == -1 ) { -- 2.39.5