diff --git a/mx_getopt.c b/mx_getopt.c index 1ef82c2..0f47b35 100644 --- a/mx_getopt.c +++ b/mx_getopt.c @@ -127,8 +127,7 @@ static int find_short_option(struct mx_option *options, char **name, char **opta assert(short_opt); - if (optarg) - *optarg = NULL; + *optarg = NULL; for (i=0, idx=-1; options[i].long_opt || options[i].short_opt; i++) {