[asterisk-bugs] [Asterisk 0015583]: #exec strips too many leading and trailing quotes
Asterisk Bug Tracker
noreply at bugs.digium.com
Sat Jul 25 13:35:22 CDT 2009
A NOTE has been added to this issue.
======================================================================
https://issues.asterisk.org/view.php?id=15583
======================================================================
Reported By: pkempgen
Assigned To:
======================================================================
Project: Asterisk
Issue ID: 15583
Category: Core/Configuration
Reproducibility: always
Severity: tweak
Priority: normal
Status: feedback
Asterisk Version: SVN
Regression: No
SVN Branch (only for SVN checkouts, not tarball releases): 1.4
SVN Revision (number only!): 176029
Request Review:
======================================================================
Date Submitted: 2009-07-25 12:00 CDT
Last Modified: 2009-07-25 13:35 CDT
======================================================================
Summary: #exec strips too many leading and trailing quotes
Description:
#exec (main/config.c) strips leading and trailing quotes ("<>)
from the command which is a good thing but it strips too many.
Affects 1.4 and probably 1.6.* and trunk as well.
======================================================================
----------------------------------------------------------------------
(0108225) pkempgen (reporter) - 2009-07-25 13:35
https://issues.asterisk.org/view.php?id=15583#c108225
----------------------------------------------------------------------
My assumption was based on a diff (from 1.4 to 1.6.3 or trunk) of
what I think is the relevant code.
---cut---
/* Strip off leading and trailing "'s and <>'s */
- while((*c == '<') || (*c == '>') || (*c == '\"')) c++;
+ while ((*c == '<') || (*c == '>') || (*c == '\"')) c++;
/* Get rid of leading mess */
cur = c;
+ cur2 = cur;
while (!ast_strlen_zero(cur)) {
c = cur + strlen(cur) - 1;
if ((*c == '>') || (*c == '<') || (*c == '\"'))
*c = '\0';
else
break;
}
---cut---
I don't find anything that should cause a different behavior.
Issue History
Date Modified Username Field Change
======================================================================
2009-07-25 13:35 pkempgen Note Added: 0108225
======================================================================
More information about the asterisk-bugs
mailing list