From f4c4ba55c74982e03bc41852156dac857d91b06d Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Mon, 7 Oct 2019 20:25:06 +0200 Subject: Minor fixes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- cg-base.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'cg-base.c') diff --git a/cg-base.c b/cg-base.c index d98c9ed..ad03937 100644 --- a/cg-base.c +++ b/cg-base.c @@ -572,7 +572,9 @@ main(int argc, char *argv[]) } opt[0] = *args++; opt[2] = '\0'; - if ((*opt != '-') && (*opt != '+')) + if (*opt != '-' && *opt != '+') + break; + if (!*args) break; while (*args) { opt[1] = *args++; -- cgit v1.2.3-70-g09d2