diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-02-18 11:11:57 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:48:30 -0500 |
commit | 5ccf0bd16a962d407020062ce0fe90ad0d051f95 (patch) | |
tree | 77918ef2c99085a9a07e50a2c26a4dc2af052ff0 /source4/torture | |
parent | 4ea28ef7c0752a0907cac789b06a613580803721 (diff) | |
download | samba-5ccf0bd16a962d407020062ce0fe90ad0d051f95.tar.gz samba-5ccf0bd16a962d407020062ce0fe90ad0d051f95.tar.bz2 samba-5ccf0bd16a962d407020062ce0fe90ad0d051f95.zip |
r21421: Fix a memleak. This made tdb look considerably worse than necessary.
Volker
(This used to be commit 573ba38722e338fb4158dfda181308a1a736c5c0)
Diffstat (limited to 'source4/torture')
-rw-r--r-- | source4/torture/local/dbspeed.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source4/torture/local/dbspeed.c b/source4/torture/local/dbspeed.c index 08012fc5e9..2dce343483 100644 --- a/source4/torture/local/dbspeed.c +++ b/source4/torture/local/dbspeed.c @@ -96,6 +96,7 @@ static BOOL test_tdb_speed(struct torture_context *torture, const void *_data) key.dptr = (uint8_t *)talloc_asprintf(tmp_ctx, "S-1-5-21-53173311-3623041448-2049097239-%u", i); key.dsize = strlen((char *)key.dptr)+1; data = tdb_fetch(tdbw->tdb, key); + talloc_free(key.dptr); if (data.dptr == NULL) { torture_result(torture, TORTURE_FAIL, "Failed to fetch SID %d\n", i); goto failed; @@ -104,6 +105,7 @@ static BOOL test_tdb_speed(struct torture_context *torture, const void *_data) key.dptr = (uint8_t *)talloc_asprintf(tmp_ctx, "UID %u", i); key.dsize = strlen((char *)key.dptr)+1; data = tdb_fetch(tdbw->tdb, key); + talloc_free(key.dptr); if (data.dptr == NULL) { torture_result(torture, TORTURE_FAIL, "Failed to fetch UID %d\n", i); goto failed; |