* support/ab.c (main): Check apr_getopt() returned APR_EOF, fixing clang
warning:
support/ab.c:2343:13: warning[deadcode.DeadStores]: Although the value stored to 'status' is used in the enclosing expression, the value is never actually read from 'status'
@@ -2592,8 +2592,8 @@ int main(int argc, const char * const argv[])
}
}
- if (opt->ind != argc - 1) {
- fprintf(stderr, "%s: wrong number of arguments\n", argv[0]);
+ if (status != APR_EOF || opt->ind != argc - 1) {
+ fprintf(stderr, "%s: Invalid or missing arguments\n", argv[0]);
usage(argv[0]);
}
