]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Make sure values are interpreted as character strings and not format strings.
authorJoshua Colp <jcolp@digium.com>
Tue, 18 Mar 2008 15:13:07 +0000 (15:13 +0000)
committerJoshua Colp <jcolp@digium.com>
Tue, 18 Mar 2008 15:13:07 +0000 (15:13 +0000)
(AST-2008-004)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@109396 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/logger.c
main/manager.c

index b0b728b78ad8d4ddac29234dfc2df62655d79a8e..072a23bb2844b4d18bec5efb7aa88b8303e3eb96 100644 (file)
@@ -1145,7 +1145,7 @@ void ast_verbose(const char *fmt, ...)
 
        strcpy(logmsg->str, buf->str);
 
-       ast_log(LOG_VERBOSE, logmsg->str);
+       ast_log(LOG_VERBOSE, "%s", logmsg->str);
 
        /* Set type */
        logmsg->type = LOGMSG_VERBOSE;
index 7633b6e3f4703cc5326117b5700c39a7409817b2..1d4ff18577ebf295750998f34dbc546443104906 100644 (file)
@@ -2051,7 +2051,7 @@ static int action_command(struct mansession *s, const struct message *m)
                        term_strip(final_buf, buf, l);
                        final_buf[l] = '\0';
                }
-               astman_append(s, S_OR(final_buf, buf));
+               astman_append(s, "%s", S_OR(final_buf, buf));
                ast_free(buf);
        }
        close(fd);