From c28a605bbdcc2b690898a94394bc54d648051d90 Mon Sep 17 00:00:00 2001 From: Jeff Peeler Date: Wed, 9 Feb 2011 21:06:33 +0000 Subject: [PATCH] Add missing debug info for ao2_link for use with REF_DEBUG in ao2 callback. (closes issue #18758) Reported by: rgagnon Patches: branch-1.8-r306540-astobj-fix.diff uploaded by rgagnon (license 1202) trunk-r306540-astobj-fix.diff uploaded by rgagnon (license 1202) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@307273 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- main/astobj2.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/main/astobj2.c b/main/astobj2.c index 07d46bb6fd..3e853a7a27 100644 --- a/main/astobj2.c +++ b/main/astobj2.c @@ -693,7 +693,11 @@ static void *internal_ao2_callback(struct ao2_container *c, * link the object into the container that will hold the results. */ if (ret && (multi_container != NULL)) { - __ao2_link(multi_container, ret); + if (tag) { + __ao2_link_debug(multi_container, ret, tag, file, line, funcname); + } else { + __ao2_link(multi_container, ret); + } ret = NULL; }