I am trying to use SoftHangup in my dialplan, but it's either not working or I'm not using it correctly.

when i'm on the console, i see:
pbx1*CLI> core show channels
Channel           Location          State Application(Data)
SIP/vgw1-000000a2 2156181505@inbound:1 Up AppDial((Outgoing Line))
SIP/143-0000009f  s@macro-SaferSIPDial Up Dial(SIP/99302156181505@vgw1,,
2 active channels
1 active call
194 calls processed
pbx1*CLI>


in my dialplan, i have:
exten => s,1,Set(CHAN=${SHELL(asterisk -rx "core show channels" | awk '/^SIP\/vgw1-/ { print $1 }' | head -1)})
exten => s,n,SoftHangup(${CHAN})
exten => s,n,Wait(2)



When I dial the extension to invoke the above dialplan code, the console shows: -- Executing [s@nineoneone:10] SoftHangup("SIP/111-000000a3", "SIP/vgw1-000000a2") in new stack

but the SIP/vgw1-000000a2 is still active. If I use 'channel request hangup SIP/vgw1-000000a2', the call is dropped instantly.

Am I using SoftHangup incorrectly?


--

Jeremy Kister
http://jeremy.kister.net./

--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
              http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to