mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-02 20:08:17 +00:00
Minor change to 318141 to improve parsing behavior.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@318193 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -4501,7 +4501,11 @@ static int park_exec_full(struct ast_channel *chan, const char *data)
|
|||||||
const char *lotname_split = NULL; /* name of the parking lot if an '@' symbol is included in data */
|
const char *lotname_split = NULL; /* name of the parking lot if an '@' symbol is included in data */
|
||||||
|
|
||||||
if (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)'@'))) {
|
if ((lotname_split = strchr(data, (int)'@'))) {
|
||||||
lotname_split++;
|
lotname_split++;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user