winbind: Fix CID 1398530 Resource leak
authorVolker Lendecke <vl@samba.org>
Tue, 10 Jan 2017 13:29:38 +0000 (13:29 +0000)
committerJeremy Allison <jra@samba.org>
Wed, 11 Jan 2017 03:38:25 +0000 (04:38 +0100)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed Jan 11 04:38:25 CET 2017 on sn-devel-144

source3/winbindd/winbindd_cache.c

index d92c050ee70dcae634d25dc43394be1bbc828f06..4431cb52b64ae3297474f898269dd4caf0a4337a 100644 (file)
@@ -1457,6 +1457,7 @@ do_fetch_cache:
 
        rids = talloc_array(mem_ctx, uint32_t, num_rids);
        if (rids == NULL) {
+               centry_free(centry);
                return NT_STATUS_NO_MEMORY;
        }