git.samba.org
/
metze
/
samba
/
wb-ndr.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6deca23
)
talloc_free_children can only reset pool if it's empty
author
Volker Lendecke
<vl@samba.org>
Thu, 10 Jan 2008 10:35:17 +0000
(11:35 +0100)
committer
Michael Adam
<obnox@samba.org>
Mon, 11 Feb 2008 14:07:46 +0000
(15:07 +0100)
source/lib/talloc/talloc.c
patch
|
blob
|
history
diff --git
a/source/lib/talloc/talloc.c
b/source/lib/talloc/talloc.c
index 9e935b892c22ba6e4be7485b5903eb076e16618f..35ed447e45c723c21146d2d045ee26a90d388cb4 100644
(file)
--- a/
source/lib/talloc/talloc.c
+++ b/
source/lib/talloc/talloc.c
@@
-866,7
+866,8
@@
void talloc_free_children(void *ptr)
}
}
- if (tc->flags & TALLOC_FLAG_POOL) {
+ if ((tc->flags & TALLOC_FLAG_POOL)
+ && (*talloc_pool_objectcount(tc) == 1)) {
tc->pool = ((char *)tc + TC_HDR_SIZE + TALLOC_POOL_HDR_SIZE);
#if defined(DEVELOPER) && defined(VALGRIND_MAKE_MEM_NOACCESS)
VALGRIND_MAKE_MEM_NOACCESS(