Skip to contentSkip to conversation

Fix build failure with gcc -Werror=format-security

PATCH New Petr Šabata 1 participant 1 message Jun 24, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix build failure with gcc -Werror=format-security

This fix lets dash build with the abovementioned option.

---
 src/jobs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
src/jobs.c +1 -1
index bf40204..f3af44d 100644
@@ -427,7 +427,7 @@ sprint_status(char *s, int status, int sigonly)
 				goto out;
 #endif
 		}
-		col = fmtstr(s, 32, strsignal(st));
+		col = fmtstr(s, 32, "%s", strsignal(st));
 #ifdef WCOREDUMP
 		if (WCOREDUMP(status)) {
 			col += fmtstr(s + col, 16, " (core dumped)");
Signature · 1 line
1.9.3