search for: handlehangupbycallerorp

Displaying 3 results from an estimated 3 matches for "handlehangupbycallerorp".

2018 Jun 05
2
How to execute priorities following a caller hangup in a successful Dial?
...handler, but it's showing a similar problem: When the peer hangs-up, the hangup handler is not invoked and the caller channel remains open. same => n(callPeer),Set(GLOBAL(Peer${IndexIntoPeers}CurrentCallsCount)=$[${PeerCurrentCallsCount} + 1]) same => n,Set(CHANNEL(hangup_handler_push)=handleHangupByCallerOrPeer,doesntMatter,1(args)) same => n,Set(DialForPeer=SIP/${EXTEN:0:4}@${PeerBeingConsidered}) same => n,Dial(${DialForPeer}) same => n,Hangup() [handleHangupByCallerOrPeer] exten => _.,1,NoOp(${PeerBeingConsidered}: Entered handleHangupByCallerOrPeer Calls ${Peer${IndexIntoPeers}Curre...
2018 Jun 05
2
How to execute priorities following a caller hangup in a successful Dial?
...> s,1,Set(CHANNEL(hangup_handler_push)=handleHangupByPeer,s,1(args)) same => n,Return [handleHangupByPeer] ; Ensure that GLOBAL(CB${IndexIntoPeers}CurrentCallsCount) is decremented after hangup, and end-of-call-epoch is set. exten => s,1,NoOp(${PeerBeingConsidered} peer channel: Entered handleHangupByCallerOrPeer Calls ${CB${IndexIntoPeers}CurrentCallsCount}) same => n,Set(GLOBAL(CB${IndexIntoPeers}CurrentCallsCount)=$[${CB${IndexIntoPeers}CurrentCallsCount} - 1]) same => n,Set(GLOBAL(${PeerBeingConsidered}EpochAtCallEnd)=${EPOCH}) same => n,Return [handleHangupByCaller] ; Ensure that GLOBA...
2018 Jun 05
2
How to execute priorities following a caller hangup in a successful Dial?
Thanks, Anthony. I added both 'g' and 'F' options. Now, when the caller hangs-up, my cleanup code is run by both the caller channel and the peer channel, but I only want the caller channel to do that. Also, when the peer hangs-up, there is no execution of the priorities following the Dial. Finally, is there a way to reset all globals, maybe as a variant of "dialplan