summaryrefslogtreecommitdiff
path: root/include/asterisk/astobj2.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asterisk/astobj2.h')
-rw-r--r--include/asterisk/astobj2.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/asterisk/astobj2.h b/include/asterisk/astobj2.h
index 3b93a029e..c682baa39 100644
--- a/include/asterisk/astobj2.h
+++ b/include/asterisk/astobj2.h
@@ -1757,6 +1757,12 @@ void ao2_bt(void); /* backtrace */
* \note they must be able to handle NULL parameters because most of the
* allocation/find functions can fail and we don't want to try to tear
* down a NULL */
-void ao2_cleanup(void *obj);
+void __ao2_cleanup(void *obj);
+void __ao2_cleanup_debug(void *obj, const char *file, int line, const char *function);
+#ifdef REF_DEBUG
+#define ao2_cleanup(obj) __ao2_cleanup_debug((obj), __FILE__, __LINE__, __PRETTY_FUNCTION__)
+#else
+#define ao2_cleanup(obj) __ao2_cleanup(obj)
+#endif
void ao2_iterator_cleanup(struct ao2_iterator *iter);
#endif /* _ASTERISK_ASTOBJ2_H */