]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
sparc: use %s for unaligned panic
authorKees Cook <keescook@chromium.org>
Mon, 30 Jun 2014 20:37:59 +0000 (13:37 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 22 Jul 2014 04:37:06 +0000 (21:37 -0700)
Since unaligned_panic() takes a literal string, make sure it can never
accidentally be used as a format string.

Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
arch/sparc/kernel/unaligned_32.c

index c5c61b3c6b56f30d40165179e1e851d8859f6bd3..32b61d1b637981b711669e2c864c0ffe186cfb13 100644 (file)
@@ -166,7 +166,7 @@ unsigned long safe_compute_effective_address(struct pt_regs *regs,
 /* This is just to make gcc think panic does return... */
 static void unaligned_panic(char *str)
 {
-       panic(str);
+       panic("%s", str);
 }
 
 /* una_asm.S */