summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMasahiro Yamada <yamada.masahiro@socionext.com>2017-02-02 16:34:14 +0900
committerMasahiro Yamada <yamada.masahiro@socionext.com>2017-02-11 13:00:27 +0900
commit95d2b2682b54d780c99ab8d8411aac7a55171a8c (patch)
treeb3ca26755fee959d5b578c3da77e96cb4229dd1e /tools
parentbab16f9912c6a2ea7600e8d713c1eebf8f0c11d7 (diff)
fiptool: print new lines of usage to stdout instead of stderr
The strings in usage functions are sent to stdout by printf(), but some new lines are sent to stderr by fputc(..., stderr). This inconsistency will break the usage format when users re-direct stdout or stderr. Just use printf() for consistency. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/fiptool/fiptool.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/fiptool/fiptool.c b/tools/fiptool/fiptool.c
index 865aeae1..8cf7ecec 100644
--- a/tools/fiptool/fiptool.c
+++ b/tools/fiptool/fiptool.c
@@ -826,7 +826,7 @@ static void create_usage(void)
"pointed to by file.\n");
printf(" --plat-toc-flags <value>\t16-bit platform specific flag field "
"occupying bits 32-47 in 64-bit ToC header.\n");
- fputc('\n', stderr);
+ printf("\n");
printf("Specific images are packed with the following options:\n");
for (; toc_entry->cmdline_name != NULL; toc_entry++)
printf(" --%-16s FILENAME\t%s\n", toc_entry->cmdline_name,
@@ -943,7 +943,7 @@ static void update_usage(void)
printf(" --out FIP_FILENAME\t\tSet an alternative output FIP file.\n");
printf(" --plat-toc-flags <value>\t16-bit platform specific flag field "
"occupying bits 32-47 in 64-bit ToC header.\n");
- fputc('\n', stderr);
+ printf("\n");
printf("Specific images are packed with the following options:\n");
for (; toc_entry->cmdline_name != NULL; toc_entry++)
printf(" --%-16s FILENAME\t%s\n", toc_entry->cmdline_name,
@@ -1081,12 +1081,12 @@ static void unpack_usage(void)
printf(" --force\t\t\tIf the output file already exists, use --force to "
"overwrite it.\n");
printf(" --out path\t\t\tSet the output directory path.\n");
- fputc('\n', stderr);
+ printf("\n");
printf("Specific images are unpacked with the following options:\n");
for (; toc_entry->cmdline_name != NULL; toc_entry++)
printf(" --%-16s FILENAME\t%s\n", toc_entry->cmdline_name,
toc_entry->name);
- fputc('\n', stderr);
+ printf("\n");
printf("If no options are provided, all images will be unpacked.\n");
exit(1);
}
@@ -1210,7 +1210,7 @@ static void remove_usage(void)
printf(" --force\t\tIf the output FIP file already exists, use --force to "
"overwrite it.\n");
printf(" --out FIP_FILENAME\tSet an alternative output FIP file.\n");
- fputc('\n', stderr);
+ printf("\n");
printf("Specific images are removed with the following options:\n");
for (; toc_entry->cmdline_name != NULL; toc_entry++)
printf(" --%-16s\t%s\n", toc_entry->cmdline_name,
@@ -1258,7 +1258,7 @@ static void usage(void)
printf("usage: fiptool [--verbose] <command> [<args>]\n");
printf("Global options supported:\n");
printf(" --verbose\tEnable verbose output for all commands.\n");
- fputc('\n', stderr);
+ printf("\n");
printf("Commands supported:\n");
printf(" info\t\tList images contained in FIP.\n");
printf(" create\tCreate a new FIP with the given images.\n");