[asterisk-commits] jrose: trunk r318193 - /trunk/main/features.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon May 9 09:37:15 CDT 2011
Author: jrose
Date: Mon May 9 09:37:10 2011
New Revision: 318193
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=318193
Log:
Minor change to 318141 to improve parsing behavior.
Modified:
trunk/main/features.c
Modified: trunk/main/features.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/features.c?view=diff&rev=318193&r1=318192&r2=318193
==============================================================================
--- trunk/main/features.c (original)
+++ trunk/main/features.c Mon May 9 09:37:10 2011
@@ -4501,7 +4501,11 @@
const char *lotname_split = NULL; /* name of the parking lot if an '@' symbol is included in data */
if (data) {
- sscanf(data, "%d", &park);
+ if (sscanf(data, "%u", &park) != 1) {
+ /* Something went wrong when parsing the extension */
+ ast_log(LOG_WARNING, "Could not parse extension from '%s'\n", data);
+ return -1;
+ }
if ((lotname_split = strchr(data, (int)'@'))) {
lotname_split++;
}
More information about the asterisk-commits
mailing list