aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-05 13:43:12 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2009-05-05 13:43:12 +0000
commit32ec5c1cf52cc482432911f72e56f80edf2cc02e (patch)
treebcaa9728025187a8b3bbbb17ec7785f395f9fc5c /main
parent12f6b763d206e5a57e07f45eabd90c7f8c61fd49 (diff)
Merged revisions 192357 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r192357 | kpfleming | 2009-05-05 15:18:21 +0200 (Tue, 05 May 2009) | 5 lines Correct some flaws in the memory accounting code for stringfields and ao2 objects Under some conditions, the memory allocation for stringfields and ao2 objects would not have supplied valid file/function names for MALLOC_DEBUG tracking, so this commit corrects that. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@192360 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main')
-rw-r--r--main/astobj2.c2
-rw-r--r--main/utils.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/main/astobj2.c b/main/astobj2.c
index cf3b2c821..89790b08c 100644
--- a/main/astobj2.c
+++ b/main/astobj2.c
@@ -358,7 +358,7 @@ void *_ao2_alloc_debug(size_t data_size, ao2_destructor_fn destructor_fn, char *
void *_ao2_alloc(size_t data_size, ao2_destructor_fn destructor_fn)
{
- return __ao2_alloc(data_size, destructor_fn, NULL, 0, NULL);
+ return __ao2_alloc(data_size, destructor_fn, __FILE__, __LINE__, __FUNCTION__);
}
diff --git a/main/utils.c b/main/utils.c
index 313a5eb82..c1e63f972 100644
--- a/main/utils.c
+++ b/main/utils.c
@@ -1575,7 +1575,7 @@ ast_string_field __ast_string_field_alloc_space(struct ast_string_field_mgr *mgr
if (add_string_pool(mgr, pool_head, new_size, mgr->owner_file, mgr->owner_line, mgr->owner_func))
return NULL;
#else
- if (add_string_pool(mgr, pool_head, new_size, NULL, 0, NULL))
+ if (add_string_pool(mgr, pool_head, new_size, __FILE__, __LINE__, __FUNCTION__))
return NULL;
#endif
}