diff options
author | Matt Jordan <mjordan@digium.com> | 2015-09-05 18:48:31 -0500 |
---|---|---|
committer | Gerrit Code Review <gerrit2@gerrit.digium.api> | 2015-09-05 18:48:31 -0500 |
commit | 24be90c6d7806757c48331233133a74f7ad1482e (patch) | |
tree | 3d5d59ee7e88ee124af2a10f9f002ec167d9889e | |
parent | 319fe8224fd2a35462b13bd554c02b8e07694121 (diff) | |
parent | 6002472a6286eabb5bba79282b62ba2a629a0660 (diff) |
Merge "endpoint snapshot: avoid second cleanup on alloc failure" into 13
-rw-r--r-- | main/endpoints.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/main/endpoints.c b/main/endpoints.c index ce0ab0292..0155adfeb 100644 --- a/main/endpoints.c +++ b/main/endpoints.c @@ -464,7 +464,7 @@ static void endpoint_snapshot_dtor(void *obj) struct ast_endpoint_snapshot *ast_endpoint_snapshot_create( struct ast_endpoint *endpoint) { - RAII_VAR(struct ast_endpoint_snapshot *, snapshot, NULL, ao2_cleanup); + struct ast_endpoint_snapshot *snapshot; int channel_count; struct ao2_iterator i; void *obj; @@ -500,7 +500,6 @@ struct ast_endpoint_snapshot *ast_endpoint_snapshot_create( } ao2_iterator_destroy(&i); - ao2_ref(snapshot, +1); return snapshot; } |