[asterisk-dev] [Code Review] Allow non-normal execution routines to be able to run on hungup channels.

rmudgett reviewboard at asterisk.org
Tue Jun 12 19:53:03 CDT 2012


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/1984/
-----------------------------------------------------------

(Updated June 12, 2012, 7:53 p.m.)


Review request for Asterisk Developers.


Changes
-------

* Fixed ability to support relative non-normal dialplan execution routines.  (i.e., The context and exten are optional for the specified dialplan location.)  Predial routines are the only non-normal routines that it makes sense to optionally omit the context and exten.

* Fixed the AGI gosub application so it cleans up the dialplan execution stack and handles the autoloop priority increments correctly.

* Eliminated the need for the gosub_virtual_context return location.

* Removed the temporary Fred application.


Summary
-------

* Make non-normal dialplan execution routines be able to run on a hung up channel.  This is preparation work for hangup handler routines.

* Fixes non-normal execution routines like connected line interception and predial leaving the dialplan execution stack unbalanced.  Errors like missing Return statements, popping too many stack frames using StackPop, or an application returning non-zero could leave the dialplan stack unbalanced.

* Make Hangup set a softhangup flag.  The Hangup application used to just return -1 to cause normal dialplan execution to hangup a channel.  For the non-normal execution routines like predial and connected-line interception routines, the hangup request would be ignored.


Diffs (updated)
-----

  /trunk/apps/app_dial.c 368848 
  /trunk/apps/app_followme.c 368848 
  /trunk/apps/app_queue.c 368848 
  /trunk/apps/app_stack.c 368848 
  /trunk/include/asterisk/app.h 368848 
  /trunk/main/app.c 368848 
  /trunk/main/ccss.c 368848 
  /trunk/main/channel.c 368848 
  /trunk/main/pbx.c 368848 

Diff: https://reviewboard.asterisk.org/r/1984/diff


Testing
-------

* Used the Fred application to test running a non-normal execution routine while a channel is hung up.  (The Fred routine will be removed since it is only for testing.)
* Checked StackPop being used too many times on non-normal routines.
* Checked forgetting Return on a non-normal routine.
* Checked using Hangup in a non-normal routine causes the channel to be hung up.


Thanks,

rmudgett

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20120613/47f13b7b/attachment.htm>


More information about the asterisk-dev mailing list