cmdline (merge-intel): fix format string in snprintf()
authorOlivier Matz <zer0@droids-corp.org>
Fri, 24 Dec 2010 12:56:26 +0000 (13:56 +0100)
committerOlivier Matz <zer0@droids-corp.org>
Sun, 2 Jan 2011 20:53:15 +0000 (21:53 +0100)
Signed-off-by: Olivier Matz <olivier.matz@6wind.com>
src/lib/cmdline.c

index e6662bd..0035f44 100644 (file)
@@ -113,7 +113,7 @@ cmdline_write_char(struct rdline *rdl, char c)
 void
 cmdline_set_prompt(struct cmdline *cl, const char *prompt)
 {
-       snprintf(cl->prompt, sizeof(cl->prompt), prompt);
+       snprintf(cl->prompt, sizeof(cl->prompt), "%s", prompt);
 }
 
 struct cmdline *