[asterisk-dev] [Code Review] Clean up asterisk.conf parsing

wdoekes reviewboard at asterisk.org
Sat Sep 24 02:58:46 CDT 2011


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



trunk/main/asterisk.c
<https://reviewboard.asterisk.org/r/1462/#comment8574>

    This should be a "const char *". Even though gcc doesn't complain, writing to config[0] will get you a segfault.



trunk/main/asterisk.c
<https://reviewboard.asterisk.org/r/1462/#comment8575>

    I would prefer an early error here. There are lots and lots of options (*) that aren't restored to their default in the new code here between FILEUNCANGED and FILEINVALID. If you leave it like it was, it is clearer that you cannot simply call the function again to get the same reload functionality as you can with the other files that do support reload.
    
    (*) ast_language_is_prefix, cfg_paths.system_name, option_maxfiles, to name only a few.


- wdoekes


On Sept. 23, 2011, 9:39 p.m., Paul Belanger wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/1462/
> -----------------------------------------------------------
> 
> (Updated Sept. 23, 2011, 9:39 p.m.)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Summary
> -------
> 
> Last one for the day :D  This is pretty minor clean up of asterisk.conf
> 
> 
> Diffs
> -----
> 
>   trunk/main/asterisk.c 337894 
> 
> Diff: https://reviewboard.asterisk.org/r/1462/diff
> 
> 
> Testing
> -------
> 
> local development box
> 
> 
> Thanks,
> 
> Paul
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20110924/1e1e0b17/attachment.htm>


More information about the asterisk-dev mailing list