[Home]

Summary:ASTERISK-09973: [PATCH] Device state shows Hold after SIP native transfer
Reporter:Julian J. M. (julianjm)Labels:
Date Opened:2007-07-27 08:23:17Date Closed:2007-07-27 11:12:25
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Channels/chan_sip/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) chan_sip_device_state_hold_fix.v1.diff.txt
Description:The sip peer Hold status is updated twice after a native transfer. The internal onHold variable for the sip peer is decremented twice (the second time being in __sip_destroy()), thus always showing "State:Hold" afterwards.

CLI> core show hints
                   205@ext-local           : SIP/205               State:Idle            Watchers  0
                   202@ext-local           : SIP/202               State:Idle            Watchers  0
                   201@ext-local           : SIP/201               State:Idle            Watchers  0


202 calls 201 (polycom 501), which blindly transfers to 205. The result:


CLI> core show hints
                   205@ext-local           : SIP/205               State:Idle            Watchers  0
                   202@ext-local           : SIP/202               State:Idle            Watchers  0
                   201@ext-local           : SIP/201               State:Hold            Watchers  0


This breaks BLF, but also affects FreePBX, because it uses the ExtensionState manager action to check if a particular extension is Idle.

The attached patch clears the HOLD flag from the SIP channel as needed.
Comments:By: Digium Subversion (svnbot) 2007-07-27 11:10:00

Repository: asterisk
Revision: 77536

------------------------------------------------------------------------
r77536 | file | 2007-07-27 11:10:00 -0500 (Fri, 27 Jul 2007) | 6 lines

(closes issue ASTERISK-9973)
Reported by: julianjm
Patches:
     chan_sip_device_state_hold_fix.v1.diff.txt uploaded by julianjm (license 99)
Clear ONHOLD flag when decrementing the onHold peer count. If we did not do this the count may keep decreasing.

------------------------------------------------------------------------

By: Digium Subversion (svnbot) 2007-07-27 11:12:25

Repository: asterisk
Revision: 77537

------------------------------------------------------------------------
r77537 | file | 2007-07-27 11:12:25 -0500 (Fri, 27 Jul 2007) | 14 lines

Merged revisions 77536 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r77536 | file | 2007-07-27 13:27:16 -0300 (Fri, 27 Jul 2007) | 6 lines

(closes issue ASTERISK-9973)
Reported by: julianjm
Patches:
     chan_sip_device_state_hold_fix.v1.diff.txt uploaded by julianjm (license 99)
Clear ONHOLD flag when decrementing the onHold peer count. If we did not do this the count may keep decreasing.

........

------------------------------------------------------------------------