[SCM] Samba Shared Repository - branch master updated

Volker Lendecke vlendec at samba.org
Sun Mar 20 04:27:01 MDT 2011


The branch, master has been updated
       via  4828fed s3: Fix early tldap_search cancels
      from  a8eea9e lib/replace/test: Add missing include for prototype.

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 4828feddb7e45d1fa4509717ad8f6be281cc84dd
Author: Volker Lendecke <vl at samba.org>
Date:   Sun Mar 20 10:35:18 2011 +0100

    s3: Fix early tldap_search cancels
    
    A callback of tldap_search_send might not interested in the rest of the results
    and could do a TALLOC_FREE of the search request. In this case, "subreq" is
    already free'ed. So we have to set it to pending before the callback is called.
    The TALLOC_FREE of the search request will set it to non-pending again via
    tldap_msg_destructor.
    
    Autobuild-User: Volker Lendecke <vlendec at samba.org>
    Autobuild-Date: Sun Mar 20 11:26:57 CET 2011 on sn-devel-104

-----------------------------------------------------------------------

Summary of changes:
 source3/lib/tldap.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/lib/tldap.c b/source3/lib/tldap.c
index db5d562..2f45a05 100644
--- a/source3/lib/tldap.c
+++ b/source3/lib/tldap.c
@@ -1703,11 +1703,11 @@ static void tldap_search_done(struct tevent_req *subreq)
 	switch (state->result->type) {
 	case TLDAP_RES_SEARCH_ENTRY:
 	case TLDAP_RES_SEARCH_REFERENCE:
-		tevent_req_notify_callback(req);
 		if (!tldap_msg_set_pending(subreq)) {
 			tevent_req_nomem(NULL, req);
 			return;
 		}
+		tevent_req_notify_callback(req);
 		break;
 	case TLDAP_RES_SEARCH_RESULT:
 		TALLOC_FREE(subreq);


-- 
Samba Shared Repository


More information about the samba-cvs mailing list