r26679: It is very bad to free the ldb handle when you didn't create it...
authorAndrew Bartlett <abartlet@samba.org>
Mon, 7 Jan 2008 06:46:39 +0000 (00:46 -0600)
committerStefan Metzmacher <metze@samba.org>
Mon, 7 Jan 2008 00:51:02 +0000 (18:51 -0600)
(My bad when copying this code into samdb_is_gc()).

Andrew Bartlett

source/dsdb/common/util.c

index 17a20199d51473b2dc8e5a1c1a2f5f819a44d909..bee1eac480b3993d25aa652d2bb1e3894d6882e8 100644 (file)
@@ -1395,7 +1395,7 @@ bool samdb_is_gc(struct ldb_context *ldb)
 
        options = ldb_msg_find_attr_as_int(res->msgs[0], "options", 0);
        talloc_free(res);
-       talloc_free(ldb);
+       talloc_free(tmp_ctx);
 
        /* if options attribute has the 0x00000001 flag set, then enable the global catlog */
        if (options & 0x000000001) {