]> git.sur5r.net Git - openldap/commitdiff
Revert last commit.
authorKurt Zeilenga <kurt@openldap.org>
Sat, 9 Oct 2004 06:13:47 +0000 (06:13 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Sat, 9 Oct 2004 06:13:47 +0000 (06:13 +0000)
return 0 on timeout is actually correct.

libraries/libldap/result.c

index 44c0e98ef4ee74ce10bc24b26390e1b9247e87f8..dd41a27a9c27af7903d06c5bbed24170ddca0e6d 100644 (file)
@@ -243,13 +243,11 @@ wait4msg(
 
 #ifdef LDAP_DEBUG
        if ( timeout == NULL ) {
-               Debug( LDAP_DEBUG_TRACE,
-                       "wait4msg (infinite timeout), msgid %d\n",
-                       msgid, 0, 0 );
+               Debug( LDAP_DEBUG_TRACE, "wait4msg (infinite timeout), msgid %d\n",
+                   msgid, 0, 0 );
        } else {
-               Debug( LDAP_DEBUG_TRACE,
-                       "wait4msg (timeout %ld sec, %ld usec), msgid %d\n",
-                       (long) timeout->tv_sec, (long) timeout->tv_usec, msgid );
+               Debug( LDAP_DEBUG_TRACE, "wait4msg (timeout %ld sec, %ld usec), msgid %d\n",
+                      (long) timeout->tv_sec, (long) timeout->tv_usec, msgid );
        }
 #endif /* LDAP_DEBUG */
 
@@ -304,7 +302,7 @@ wait4msg(
                            {
                                    ld->ld_errno = (rc == -1 ? LDAP_SERVER_DOWN :
                                        LDAP_TIMEOUT);
-                                   return -1;
+                                   return( rc );
                            }
 
                            if ( rc == -1 ) {
@@ -353,7 +351,7 @@ wait4msg(
                }
        }
 
-       return rc;
+       return( rc );
 }