diff options
author | Stefan Metzmacher <metze@samba.org> | 2018-04-17 16:33:47 +0200 |
---|---|---|
committer | Ralph Boehme <slow@samba.org> | 2018-07-11 23:04:19 +0200 |
commit | 58fa08c80562490bd774f4dc774dc1ce3a042f3c (patch) | |
tree | 40fd831c11947cc3a92a17dd29605943e83d57fb /lib/tevent/tevent_internal.h | |
parent | 157df4da26aeb46eedf1a0f3895cc5fbc751f1dc (diff) | |
download | samba-58fa08c80562490bd774f4dc774dc1ce3a042f3c.tar.gz |
tevent: add tevent_common_check_double_free() helper function
This will be used to generically support TALLOC_FREE() on
event which are currently running.
It aborts on every explicit talloc_free(), but ignores implicit
cleanup when the talloc parent is about to go.
We'll undo the 0.9.36 ABI change on the 0.9.37 release
at the end of this patchset.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Diffstat (limited to 'lib/tevent/tevent_internal.h')
-rw-r--r-- | lib/tevent/tevent_internal.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/tevent/tevent_internal.h b/lib/tevent/tevent_internal.h index b13efedb5d9..7e15a59d3fb 100644 --- a/lib/tevent/tevent_internal.h +++ b/lib/tevent/tevent_internal.h @@ -248,6 +248,8 @@ void tevent_debug(struct tevent_context *ev, enum tevent_debug_level level, void tevent_abort(struct tevent_context *ev, const char *reason); +void tevent_common_check_double_free(TALLOC_CTX *ptr, const char *reason); + struct tevent_context { /* the specific events implementation */ const struct tevent_ops *ops; |