summaryrefslogtreecommitdiff
path: root/lib/talloc
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2009-07-01 16:36:10 +1000
committerAndrew Tridgell <tridge@samba.org>2009-07-01 16:37:33 +1000
commit3c2f4df55532b17ef4957604ffe411eb885edbaf (patch)
tree591e9a4b88be7571f599404e2254dec8efa894a8 /lib/talloc
parent4fb1f8e8fe46b3e77c06612ac3fc3d67cf650a11 (diff)
downloadsamba-3c2f4df55532b17ef4957604ffe411eb885edbaf.tar.gz
samba-3c2f4df55532b17ef4957604ffe411eb885edbaf.tar.bz2
samba-3c2f4df55532b17ef4957604ffe411eb885edbaf.zip
a talloc_realloc() to zero size needs to use an unambiguous free
Diffstat (limited to 'lib/talloc')
-rw-r--r--lib/talloc/talloc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/talloc/talloc.c b/lib/talloc/talloc.c
index bf2fb1f72e..e68b6539dc 100644
--- a/lib/talloc/talloc.c
+++ b/lib/talloc/talloc.c
@@ -1067,7 +1067,7 @@ void *_talloc_realloc(const void *context, void *ptr, size_t size, const char *n
/* size zero is equivalent to free() */
if (unlikely(size == 0)) {
- talloc_free(ptr);
+ talloc_unlink(context, ptr);
return NULL;
}