powerpc/xmon: avoid format string leaking to printk
PATCH 1/1 powerpc/xmon: avoid format string leaking to printk
This makes sure format strings cannot leak into printk (the string has already been correctly processed for format arguments).
Signed-off-by Kees Cook <[email protected]>
--- arch/powerpc/xmon/nonstdio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/powerpc/xmon/nonstdio.c +1 -1
@@ -122,7 +122,7 @@ void xmon_printf(const char *format, ...)if (n && rc ==0 ) {/* No udbg hooks, fallback to printk() - dangerous */ -printk (xmon_outbuf); +printk ("%s" , xmon_outbuf); } }
Signature · 6 lines
1.7.9.5 -- Kees Cook Chrome OS Security