From: Automerge Script Date: Fri, 6 Jul 2007 23:26:12 +0000 (+0000) Subject: automerge commit X-Git-Tag: 1.2.21-netsec~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9f832057141ac072d35f8d8b0ffbc1b1e615ec2f;p=thirdparty%2Fasterisk.git automerge commit git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.2-netsec@73812 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 7e8fdaf01d..29e7c49723 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -11301,8 +11301,11 @@ static int handle_request_subscribe(struct sip_pvt *p, struct sip_request *req, ast_set_flag(p, SIP_NEEDDESTROY); return 0; } - if (p->subscribed != NONE) + if (p->subscribed != NONE) { + if (p->stateid > -1) + ast_extension_state_del(p->stateid, cb_extensionstate); p->stateid = ast_extension_state_add(p->context, p->exten, cb_extensionstate, p); + } } }