summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2015-03-19 09:46:06 +0000
committerCorey Farrell <git@cfware.com>2015-03-19 09:46:06 +0000
commit2c83ac436411df216da3ecd0b8b9ef3f01422f22 (patch)
tree3fbbf3c68fd126cfb6cbdcd53623b6ee09c86fc7 /channels
parente0ea490a11da8565e0f5aa0f178324e70e2f9604 (diff)
chan_sip: Fix dialog reference leaked to scheduler for reinvite_timeout.
Release the scheduler reference to the dialog for reinvite timeout during dialog_unlink_all. ASTERISK-24876 #close Reported by: Corey Farrell Review: https://reviewboard.asterisk.org/r/4491/ ........ Merged revisions 433112 from http://svn.asterisk.org/svn/asterisk/branches/11 ........ Merged revisions 433113 from http://svn.asterisk.org/svn/asterisk/branches/13 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@433114 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 4ace51197..345c845b6 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -3340,6 +3340,10 @@ void dialog_unlink_all(struct sip_pvt *dialog)
AST_SCHED_DEL_UNREF(sched, dialog->initid, dialog_unref(dialog, "when you delete the initid sched, you should dec the refcount for the stored dialog ptr"));
+ if (dialog->reinviteid > -1) {
+ AST_SCHED_DEL_UNREF(sched, dialog->reinviteid, dialog_unref(dialog, "clear ref for reinvite_timeout"));
+ }
+
if (dialog->autokillid > -1) {
AST_SCHED_DEL_UNREF(sched, dialog->autokillid, dialog_unref(dialog, "when you delete the autokillid sched, you should dec the refcount for the stored dialog ptr"));
}