Summary: | ASTERISK-10640: dialplan save not handling ;'s correctly | ||
Reporter: | Jon Webster (jon) | Labels: | |
Date Opened: | 2007-10-29 12:33:07 | Date Closed: | 2007-10-31 13:52:16 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Core/Configuration |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ||
Description: | The extension line: exten => 8080,n,NoOp(${CUT(members|\;|1)}) when saved with 'dialplan save' looks like this: exten => 8080,n,NoOp(${CUT(members|;|1)}) and that throws the WARNING [Oct 29 12:30:36] WARNING[6737]: pbx_config.c:2292 pbx_load_config: No closing parenthesis found? 'NoOp(${CUT(members,' Writing the line as '\\;' will save as '\;'. Save it again and we are back to ';' and an error. ****** ADDITIONAL INFORMATION ****** I should also mention that all my comments are also gone. | ||
Comments: | By: Digium Subversion (svnbot) 2007-10-31 12:48:09 Repository: asterisk Revision: 87849 U branches/1.4/pbx/pbx_config.c ------------------------------------------------------------------------ r87849 | murf | 2007-10-31 12:48:08 -0500 (Wed, 31 Oct 2007) | 1 line closes issue ASTERISK-10640 -- where the 'dialplan save' cli command saves a file where the semicolon is not escaped. Fixed this; User also wanted comments to be preserved across dialplan save, but this is impossible at this point in time, because comments are not stored in the dialplan. They are 'compiled' out of extensions.conf. The only way to preserve those comments is to use the config file reader/writer that the GUI uses to allow online user edits. extensions.conf is first and foremost, a config file, and is read in by the normal config-file reading routines. Then, it is processed into a dialplan (context/exten structs). ------------------------------------------------------------------------ By: Digium Subversion (svnbot) 2007-10-31 13:52:16 Repository: asterisk Revision: 87888 _U trunk/ ------------------------------------------------------------------------ r87888 | murf | 2007-10-31 13:52:15 -0500 (Wed, 31 Oct 2007) | 9 lines Merged revisions 87849 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r87849 | murf | 2007-10-31 11:49:39 -0600 (Wed, 31 Oct 2007) | 1 line closes issue ASTERISK-10640 -- where the 'dialplan save' cli command saves a file where the semicolon is not escaped. Fixed this; User also wanted comments to be preserved across dialplan save, but this is impossible at this point in time, because comments are not stored in the dialplan. They are 'compiled' out of extensions.conf. The only way to preserve those comments is to use the config file reader/writer that the GUI uses to allow online user edits. extensions.conf is first and foremost, a config file, and is read in by the normal config-file reading routines. Then, it is processed into a dialplan (context/exten structs). (in the case of trunk, tho, no mods needed to be made -- works OK there -- just make sure you use ',' to sep app args!) ........ ------------------------------------------------------------------------ |