From 86be6a32d3fd229dbb17bf5e3348a01e6e6e855a Mon Sep 17 00:00:00 2001 From: Ruediger Meier Date: Tue, 20 Jun 2017 20:20:29 +0200 Subject: misc: cosmetics, remove argument from usage(FILE*) This patch is trivial and changes nothing, because we were always using usage(stdout) Now all our usage() functions look very similar. If wanted we could auto-generate another big cosmetical patch to remove all the useless "FILE *out" constants and use printf and puts rather than their f* friends. Such patch could be automatically synchronized with the translation project (newlines!) to not make the translators sick. Signed-off-by: Ruediger Meier --- sys-utils/blkzone.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'sys-utils/blkzone.c') diff --git a/sys-utils/blkzone.c b/sys-utils/blkzone.c index 8fd55c066..ee4902e45 100644 --- a/sys-utils/blkzone.c +++ b/sys-utils/blkzone.c @@ -290,8 +290,9 @@ static int blkzone_reset(struct blkzone_control *ctl) return 0; } -static void __attribute__((__noreturn__)) usage(FILE *out) +static void __attribute__((__noreturn__)) usage(void) { + FILE *out = stdout; size_t i; fputs(USAGE_HEADER, out); @@ -314,7 +315,7 @@ static void __attribute__((__noreturn__)) usage(FILE *out) fputs(USAGE_VERSION, out); fprintf(out, USAGE_MAN_TAIL("blkzone(8)")); - exit(out == stderr ? EXIT_FAILURE : EXIT_SUCCESS); + exit(EXIT_SUCCESS); } int main(int argc, char **argv) @@ -362,7 +363,7 @@ int main(int argc, char **argv) switch (c) { case 'h': - usage(stdout); + usage(); break; case 'c': ctl.count = strtou32_or_err(optarg, -- cgit v1.2.3-55-g7522