summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2009-05-16 20:31:59 +0200
committerKarolin Seeger <kseeger@samba.org>2009-09-09 12:45:02 +0200
commitc9594333e595c1f84c003e0a6c33a25f4226d765 (patch)
tree9bf45df92737cc6c72dbb54d41f35199c7e0c915
parentee8bb50d32830138434344f5363ff23fccce016e (diff)
downloadsamba-c9594333e595c1f84c003e0a6c33a25f4226d765.tar.gz
tevent: Define TALLOC_FREE() if it's not defined yet, to allow building with released versions of talloc. (cherry picked from commit 72b744f38ebb9f9576c05c7bb0a00de26697ec8f)
(cherry picked from commit ce80afbe3ad7534d659109e60874540531738aaf)
-rw-r--r--lib/tevent/tevent_util.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/tevent/tevent_util.h b/lib/tevent/tevent_util.h
index c4d43786e5b..829cbc2f6e6 100644
--- a/lib/tevent/tevent_util.h
+++ b/lib/tevent/tevent_util.h
@@ -116,3 +116,9 @@ do { \
const char **ev_str_list_add(const char **list, const char *s);
int ev_set_blocking(int fd, bool set);
size_t ev_str_list_length(const char **list);
+
+/* Defined here so we can build against older talloc versions that don't
+ * have this define yet. */
+#ifndef TALLOC_FREE
+#define TALLOC_FREE(ctx) do { talloc_free(ctx); ctx=NULL; } while(0)
+#endif