aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2015-09-29 05:32:57 -0500
committerRob Landley <rob@landley.net>2015-09-29 05:32:57 -0500
commit8941e5fef58025591b7441372d486cf5de46dd39 (patch)
tree478fa4729585479682ca664c639af377cd1d5af5 /lib
parent3d9dce3b523f5e4a01189d4735c02a9b33d8c7ab (diff)
downloadtoybox-8941e5fef58025591b7441372d486cf5de46dd39.tar.gz
help_exit() tweak.
Diffstat (limited to 'lib')
-rw-r--r--lib/lib.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/lib.c b/lib/lib.c
index 9e0a3a52..d9bea891 100644
--- a/lib/lib.c
+++ b/lib/lib.c
@@ -56,9 +56,11 @@ void help_exit(char *msg, ...)
if (CFG_TOYBOX_HELP) show_help(stderr);
- va_start(va, msg);
- verror_msg(msg, 0, va);
- va_end(va);
+ if (msg) {
+ va_start(va, msg);
+ verror_msg(msg, 0, va);
+ va_end(va);
+ }
xexit();
}