]> git.sur5r.net Git - openldap/commitdiff
Clean error handling
authorKurt Zeilenga <kurt@openldap.org>
Thu, 18 Dec 2003 19:30:37 +0000 (19:30 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Thu, 18 Dec 2003 19:30:37 +0000 (19:30 +0000)
clients/tools/ldapcompare.c

index df22fc77a8e77a502a36234b94db83d8fc7415bc..e9d8d0a01f146f196e91cde2b1499661f9f64f02 100644 (file)
@@ -241,18 +241,11 @@ static int docompare(
        rc = ldap_compare_ext_s( ld, dn, attr, bvalue,
                sctrls, cctrls );
 
-       if ( rc == -1 ) {
-               ldap_perror( ld, "ldap_result" );
-               return( rc );
-       }
-
        /* if we were told to be quiet, use the return value. */
        if ( !quiet ) {
                if ( rc == LDAP_COMPARE_TRUE ) {
-                       rc = 0;
                        printf(_("TRUE\n"));
                } else if ( rc == LDAP_COMPARE_FALSE ) {
-                       rc = 0;
                        printf(_("FALSE\n"));
                } else {
                        ldap_perror( ld, "ldap_compare" );