aboutsummaryrefslogtreecommitdiff
path: root/printf.c
diff options
context:
space:
mode:
Diffstat (limited to 'printf.c')
-rw-r--r--printf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/printf.c b/printf.c
index 5be3a67cb..5fd5ea303 100644
--- a/printf.c
+++ b/printf.c
@@ -143,7 +143,7 @@ printf_main(int argc, char** argv)
int args_used;
exit_status = 0;
- if ( **(argv+1) == '-' ) {
+ if ( argc <= 1 || **(argv+1) == '-' ) {
usage (printf_usage);
}