[asterisk-bugs] [Asterisk 0015338]: AstApplicationData when called with several arguments escapes comma with backslash

Asterisk Bug Tracker noreply at bugs.digium.com
Wed Jul 7 04:43:25 CDT 2010


A NOTE has been added to this issue. 
====================================================================== 
https://issues.asterisk.org/view.php?id=15338 
====================================================================== 
Reported By:                nito
Assigned To:                suretec
====================================================================== 
Project:                    Asterisk
Issue ID:                   15338
Category:                   Resources/res_config_ldap
Reproducibility:            always
Severity:                   tweak
Priority:                   normal
Status:                     assigned
Asterisk Version:           1.6.0.9 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2009-06-16 19:59 CDT
Last Modified:              2010-07-07 04:43 CDT
====================================================================== 
Summary:                    AstApplicationData when called with several
arguments escapes comma with backslash
Description: 
In my configuration we use LDAP as our database repository

With entries like this

dn: uid=jsalonen,ou=People,
AstApplication: Macro
AstExtension: 5035
AstPriority: 1
AstApplicationData: sipdial,SIP/nito,+3400012345

There is a macro in the dialplan

[macro-sipdial]
exten => ... ${ARG1} ...

and so on

on version 1.0.6-beta9 the macro was correctly called as:

Macro(sipdial,SIP/nito,+3400012345)

but since version 1.0.6.9 the macro is called as:

Macro(sipdial\,SIP/nito\,+3400012345)

That is setting a backslash for any comma that appears,




====================================================================== 

---------------------------------------------------------------------- 
 (0124293) vmikhnevych (reporter) - 2010-07-07 04:43
 https://issues.asterisk.org/view.php?id=15338#c124293 
---------------------------------------------------------------------- 
I've encountered a similar bug in 1.6.2.8, while calling a macro from
AGI-script.
The console shows:
-- AGI Script Executing Application: (ExecIf) Options:
($[${DIALSTATUS}==BUSY]?Macro(BUTTON_REDIAL,1968):NoOp(${DIALSTATUS}))
[Jul  7 12:29:34] WARNING[8788]: app_macro.c:302 _macro_exec: No such
context 'macro-BUTTON_REDIAL\' for macro 'BUTTON_REDIAL\'

Of course, there exists a context named [macro-BUTTON_REDIAL] , but it
precedes comma with a backslash somewhy. But that's not the end. If I
rename that context to [macro-BUTTON_REDIAL\] and reload dialplan, I have
another bug:

CLI> dialplan show macro-BUTTON_REDIAL\
There is no existence of 'macro-BUTTON_REDIAL ' context
Command 'dialplan show macro-BUTTON_REDIAL\ ' failed.

Keep in mind, that auto-completion was used for macro name, and "dialplan
show macro-" shows "macro-BUTTON_REDIAL\ " as one of possible matches, 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-07-07 04:43 vmikhnevych    Note Added: 0124293                          
======================================================================




More information about the asterisk-bugs mailing list