From e74a7116e5f958a9bc2b084c286a868e1dbc8375 Mon Sep 17 00:00:00 2001 From: Olle Johansson Date: Sat, 28 Jan 2006 13:52:15 +0000 Subject: [PATCH] Issue 6182 - Don't remove scheduled event until it's really done. (reported by malverian) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2@8808 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_sip.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/channels/chan_sip.c b/channels/chan_sip.c index efb40f8d6e..d687e1ace8 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -1300,7 +1300,6 @@ static int __sip_autodestruct(void *data) { struct sip_pvt *p = data; - p->autokillid = -1; /* If this is a subscription, tell the phone that we got a timeout */ if (p->subscribed) { @@ -1310,6 +1309,10 @@ static int __sip_autodestruct(void *data) append_history(p, "Subscribestatus", "timeout"); return 10000; /* Reschedule this destruction so that we know that it's gone */ } + + /* This scheduled event is now considered done. */ + p->autokillid = -1; + ast_log(LOG_DEBUG, "Auto destroying call '%s'\n", p->callid); append_history(p, "AutoDestroy", ""); if (p->owner) {