From 8d84c45d196f5d5c4209f82388df7688e7196ddd Mon Sep 17 00:00:00 2001 From: "Michael R. Torres" <6692889+micrictor@users.noreply.github.com> Date: Wed, 19 Feb 2020 20:59:36 -0800 Subject: mz: Fix accidental assignment in conditional statement Corrects the accidental assignment of _c_ to 'c' or 'p' due to a missing equals sign. This enables the proper display of the missing argument error message for all relevant options. Signed-off-by: Michael R Torres --- staging/mausezahn.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'staging') diff --git a/staging/mausezahn.c b/staging/mausezahn.c index c38ea46..6c36166 100644 --- a/staging/mausezahn.c +++ b/staging/mausezahn.c @@ -590,8 +590,8 @@ int getopts (int argc, char *argv[]) } break; case '?': - if ((optopt == 'a') || (optopt == 'b') || (optopt = 'c') || - (optopt == 'd') || (optopt == 'f') || (optopt = 'p') || + if ((optopt == 'a') || (optopt == 'b') || (optopt == 'c') || + (optopt == 'd') || (optopt == 'f') || (optopt == 'p') || (optopt == 't') || (optopt == 'm')) fprintf (stderr, " mz/getopts: Option -%c requires an argument.\n", optopt); else if (isprint (optopt)) -- cgit v1.2.3-54-g00ecf