aboutsummaryrefslogtreecommitdiffstats
path: root/main/astobj2.c
diff options
context:
space:
mode:
authorbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-06-17 21:46:57 +0000
committerbbryant <bbryant@f38db490-d61c-443f-a65b-d21fe96a405b>2008-06-17 21:46:57 +0000
commit720a492e88bee291ee8afa7559b6c0a30e205661 (patch)
tree433e912686703e932450fab80be4457b5636176a /main/astobj2.c
parent7b14a79ae755f65fdc3608a48cb0c7ffbdce5638 (diff)
Updates all usages of ast_tcptls_session_instance to be managed by reference counts so that they only get destroyed when all threads are done using
them, and memory does not get free'd causing strange issues with SIP. This code was originally written by russellb in the team/group/issue_11972/ branch. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@123546 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/astobj2.c')
-rw-r--r--main/astobj2.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/main/astobj2.c b/main/astobj2.c
index d8aaca168..e9e2db7e5 100644
--- a/main/astobj2.c
+++ b/main/astobj2.c
@@ -930,12 +930,6 @@ static char *handle_astobj2_test(struct ast_cli_entry *e, int cmd, struct ast_cl
ast_cli(a->fd, "object %d allocated as %p\n", i, obj);
sprintf(obj, "-- this is obj %d --", i);
ao2_link(c1, obj);
- /* At this point, the refcount on obj is 2 due to the allocation
- * and linking. We can go ahead and reduce the refcount by 1
- * right here so that when the container is unreffed later, the
- * objects will be freed
- */
- ao2_t_ref(obj, -1, "test");
}
ast_cli(a->fd, "testing callbacks\n");
ao2_t_callback(c1, 0, print_cb, &a->fd,"test callback");