From: Ralph Boehme Date: Tue, 5 Feb 2019 13:08:56 +0000 (+0100) Subject: tldap: avoid more use after free errors X-Git-Tag: ldb-1.6.1~226 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bf91ee0a9727cc392583fe84ad069204be758515;p=thirdparty%2Fsamba.git tldap: avoid more use after free errors See the previous commit for an explanation. :) Bug: https://bugzilla.samba.org/show_bug.cgi?id=13776 Signed-off-by: Ralph Boehme Reviewed-by: Volker Lendecke Autobuild-User(master): Ralph Böhme Autobuild-Date(master): Wed Feb 6 10:19:12 CET 2019 on sn-devel-144 --- diff --git a/source3/lib/tldap_util.c b/source3/lib/tldap_util.c index 508c6c02f80..54a9eb30bbe 100644 --- a/source3/lib/tldap_util.c +++ b/source3/lib/tldap_util.c @@ -457,7 +457,6 @@ static void tldap_fetch_rootdse_done(struct tevent_req *subreq) rc = tldap_search_recv(subreq, state, &msg); if (tevent_req_ldap_error(req, rc)) { - TALLOC_FREE(subreq); return; } @@ -739,7 +738,6 @@ static void tldap_search_paged_done(struct tevent_req *subreq) rc = tldap_search_recv(subreq, state, &state->result); if (tevent_req_ldap_error(req, rc)) { - TALLOC_FREE(subreq); return; }