mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-06 04:30:28 +00:00
Merged revisions 85515 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r85515 | russell | 2007-10-12 10:40:35 -0500 (Fri, 12 Oct 2007) | 7 lines Fix the potential use of an uninitialized buffer in a log message. (closes issue #10958) Reported by: dimas Patches: realtime.patch uploaded by dimas (license 88) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@85516 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -178,12 +178,12 @@ static int realtime_exec(struct ast_channel *chan, const char *context, const ch
|
|||||||
|
|
||||||
if (var) {
|
if (var) {
|
||||||
char *tmp="";
|
char *tmp="";
|
||||||
char app[256];
|
char *app = NULL;
|
||||||
struct ast_variable *v;
|
struct ast_variable *v;
|
||||||
|
|
||||||
for (v = var; v ; v = v->next) {
|
for (v = var; v ; v = v->next) {
|
||||||
if (!strcasecmp(v->name, "app"))
|
if (!strcasecmp(v->name, "app"))
|
||||||
ast_copy_string(app, v->value, sizeof(app));
|
app = ast_strdupa(v->value);
|
||||||
else if (!strcasecmp(v->name, "appdata"))
|
else if (!strcasecmp(v->name, "appdata"))
|
||||||
tmp = ast_strdupa(v->value);
|
tmp = ast_strdupa(v->value);
|
||||||
}
|
}
|
||||||
@@ -215,6 +215,8 @@ static int realtime_exec(struct ast_channel *chan, const char *context, const ch
|
|||||||
res = pbx_exec(chan, a, appdata);
|
res = pbx_exec(chan, a, appdata);
|
||||||
} else
|
} else
|
||||||
ast_log(LOG_NOTICE, "No such application '%s' for extension '%s' in context '%s'\n", app, exten, context);
|
ast_log(LOG_NOTICE, "No such application '%s' for extension '%s' in context '%s'\n", app, exten, context);
|
||||||
|
} else {
|
||||||
|
ast_log(LOG_WARNING, "No application specified for realtime extension '%s' in context '%s'\n", exten, context);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return res;
|
return res;
|
||||||
|
Reference in New Issue
Block a user