summaryrefslogtreecommitdiff
path: root/channels/chan_motif.c
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2015-03-13 01:12:35 +0000
committerCorey Farrell <git@cfware.com>2015-03-13 01:12:35 +0000
commitc08fd275bf8c45dc09084f104521cbff04eab25b (patch)
tree09cc14b9a9190254980ec88b981d6f561ec8a9b5 /channels/chan_motif.c
parent38ee441ea7debef3ebf6b162fc290b121fa3588d (diff)
Logger: Convert 'struct ast_callid' to unsigned int.
Switch logger callid's from AO2 objects to simple integers. This helps in two ways. Copying integers is faster than referencing AO2 objects, so this will result in a small reduction in logger overhead. This also erases the possibility of an infinate loop caused by an invalid callid in threadstorage. ASTERISK-24833 #comment Committed callid conversion to trunk. Reported by: Corey Farrell Review: https://reviewboard.asterisk.org/r/4466/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@432834 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_motif.c')
-rw-r--r--channels/chan_motif.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/channels/chan_motif.c b/channels/chan_motif.c
index 48f1b1fc7..13baa70eb 100644
--- a/channels/chan_motif.c
+++ b/channels/chan_motif.c
@@ -317,7 +317,7 @@ struct jingle_session {
struct ast_format_cap *peercap; /*!< Peer codec capabilities */
unsigned int outgoing:1; /*!< Whether this is an outgoing leg or not */
unsigned int gone:1; /*!< In the eyes of Jingle this session is already gone */
- struct ast_callid *callid; /*!< Bound session call-id */
+ ast_callid callid; /*!< Bound session call-id */
};
static const char desc[] = "Motif Jingle Channel";
@@ -585,10 +585,6 @@ static void jingle_session_destructor(void *obj)
ao2_cleanup(session->jointcap);
ao2_cleanup(session->peercap);
- if (session->callid) {
- ast_callid_unref(session->callid);
- }
-
ast_string_field_free_memory(session);
}
@@ -704,7 +700,7 @@ static void jingle_enable_video(struct jingle_session *session)
static struct jingle_session *jingle_alloc(struct jingle_endpoint *endpoint, const char *from, const char *sid)
{
struct jingle_session *session;
- struct ast_callid *callid;
+ ast_callid callid;
struct ast_sockaddr tmp;
if (!(session = ao2_alloc(sizeof(*session), jingle_session_destructor))) {