Fix processing of abbreviated negated boolean options
It was noted that "mhn -nohead" did not suppress the output of headers as "mhn -noheaders" did. It turned out that the negation marker was overwritten while scanning options for possible matching alternatives. This patch fixes it. * libmailutils/opt/opt.c (find_long_option): Don't overwrite the negation attribute of the last found option. * libmailutils/tests/parseopt.c: New option --headers, to test the fix. * libmailutils/tests/parseopt28.at: New testcase. * libmailutils/tests/Makefile.am: Add new testcase. * libmailutils/tests/testsuite.at: Include new testcase. * libmailutils/tests/parseopt*.at: Trivial changes
Showing
39 changed files
with
103 additions
and
12 deletions
libmailutils/tests/parseopt28.at
0 → 100644
-
Please register or sign in to post a comment