[asterisk-dev] [Code Review] 3222: pbx: If someone managed to get Asterisk to load with no dialplan at all, survive

opticron reviewboard at asterisk.org
Fri Feb 14 09:20:07 CST 2014


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

Ship it!


Ship It!

- opticron


On Feb. 13, 2014, 7:23 p.m., Matt Jordan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/3222/
> -----------------------------------------------------------
> 
> (Updated Feb. 13, 2014, 7:23 p.m.)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Bugs: ASTERISK-23297
>     https://issues.asterisk.org/jira/browse/ASTERISK-23297
> 
> 
> Repository: Asterisk
> 
> 
> Description
> -------
> 
> Currently, if you load Asterisk with an empty extensions.conf, and you noload all other pbx modules (such as pbx_ael), then loading a later module - such as res_parking - that attempts to add something to the dialplan will explode.
> 
> This is because ast_merge_contexts_and_delete assumes there is at least one context loaded.
> 
> This patch modifies the routine to simply set the contexts_table/contexts pointers to the merged entries if they don't exist yet.
> 
> Note that this is probably a problem in 1.8/11, however, it probably never occurred due to features.c creating the parking extensions. Now that the core no longer does that, it's slightly more plausible to end up in this situation. It still wouldn't hurt to apply this patch to 1.8/11 as well.
> 
> 
> Diffs
> -----
> 
>   ./branches/12/main/pbx.c 407935 
> 
> Diff: https://reviewboard.asterisk.org/r/3222/diff/
> 
> 
> Testing
> -------
> 
> The slightly contrived scenario no longer crashes.
> 
> 
> Thanks,
> 
> Matt Jordan
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140214/ca3e4d94/attachment.html>


More information about the asterisk-dev mailing list