[PATCH] commands: fix a warning in help.c

Masahiro Yamada yamada.m at jp.panasonic.com
Mon Jan 12 22:24:33 PST 2015


Fix the following warning:

commands/help.c: In function ‘list_group’:
commands/help.c:57:4: warning: format not a string literal and
no format arguments [-Wformat-security]
    printf(cmdtp->name);
    ^

Signed-off-by: Masahiro Yamada <yamada.m at jp.panasonic.com>
---

 commands/help.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/commands/help.c b/commands/help.c
index 8985335..6e61bde 100644
--- a/commands/help.c
+++ b/commands/help.c
@@ -54,7 +54,7 @@ static void list_group(int verbose, const char *grpname, uint32_t group)
 				printf(", ");
 				pos += 2;
 			}
-			printf(cmdtp->name);
+			puts(cmdtp->name);
 			pos += len;
 		}
 	}
-- 
1.9.1




More information about the barebox mailing list