]> git.sur5r.net Git - openldap/commitdiff
Always return SLAPD_ABANDON in response to op->o_abandon being set.
authorHoward Chu <hyc@openldap.org>
Fri, 18 Feb 2005 00:37:40 +0000 (00:37 +0000)
committerHoward Chu <hyc@openldap.org>
Fri, 18 Feb 2005 00:37:40 +0000 (00:37 +0000)
servers/slapd/back-bdb/search.c
servers/slapd/back-ldap/search.c
servers/slapd/back-ldbm/search.c
servers/slapd/back-meta/search.c
servers/slapd/back-passwd/search.c

index c770f8112b2c79cae5abfd5983f31cbfbaa31243..297e179e6a74264fda29ee08bd5560e454c9b02f 100644 (file)
@@ -649,7 +649,7 @@ loop_begin:
 
                /* check for abandon */
                if ( op->o_abandon ) {
-                       rs->sr_err = LDAP_SUCCESS;
+                       rs->sr_err = SLAPD_ABANDON;
                        goto done;
                }
 
index a2ad8a5df618b889c9e36791e71f37398405da44..a9fc57fb752cc312e0cad3065415c021f822c207 100644 (file)
@@ -138,7 +138,7 @@ fail:;
                /* check for abandon */
                if ( op->o_abandon ) {
                        ldap_abandon_ext( lc->lc_ld, msgid, NULL, NULL );
-                       rc = 0;
+                       rc = SLAPD_ABANDON;
                        goto finish;
                }
 
@@ -291,7 +291,9 @@ fail:;
        }
 
 finish:;
-       send_ldap_result( op, rs );
+       if ( rc != SLAPD_ABANDON ) {
+               send_ldap_result( op, rs );
+       }
 
        (void)ldap_back_proxy_authz_ctrl_free( op, &ctrls );
 
index 3c09594ff134efd30a3e98ddcdac976418f063a9..1e414f6609a68bb6df93f12dd6bc376ff727295f 100644 (file)
@@ -232,7 +232,7 @@ searchit:
 
                /* check for abandon */
                if ( op->o_abandon ) {
-                       rc = LDAP_SUCCESS;
+                       rc = SLAPD_ABANDON;
                        goto done;
                }
 
index ae2ce94759857f9714dacdea99c4d5c6a87e3d19..3dbd522a8be9a3b305032280a155caaef129ed33 100644 (file)
@@ -303,7 +303,7 @@ new_candidate:;
                        
                        if ( ab ) {
                                ldap_abandon_ext( lsc->msc_ld, msgid[ i ], NULL, NULL );
-                               rc = 0;
+                               rc = SLAPD_ABANDON;
                                break;
                        }
 
index cfb55531e505e5fb1b2078cdcf3eca324e7975ad..ab2c7c1a2262af6289fd10dcf39a556db774de9f 100644 (file)
@@ -143,7 +143,7 @@ passwd_back_search(
                                if ( op->o_abandon ) {
                                        endpwent();
                                        ldap_pvt_thread_mutex_unlock( &passwd_mutex );
-                                       return( -1 );
+                                       return( SLAPD_ABANDON );
                                }
 
                                /* check time limit */