diff options
author | Brendan Cully <brendan@kublai.com> | 2008-08-23 15:21:42 -0700 |
---|---|---|
committer | Brendan Cully <brendan@kublai.com> | 2008-08-23 15:21:42 -0700 |
commit | e3c2ce643d645b0da8f92579b66d95cd8d3d8e8a (patch) | |
tree | f274e814d247d71ed401b1a50160d7b8878ae806 /main.c | |
parent | a69216dced82f505ba6afd5ed9ef65ba16df9248 (diff) |
Fix infinite loop with "mutt -", introduced in [31c9e9727d42].
Treats - as a non-option argument. It would be reasonable to treat it
as an error instead.
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -582,7 +582,7 @@ int main (int argc, char **argv) */ for (; optind < argc; optind++) { - if (argv[optind][0] == '-') + if (argv[optind][0] == '-' && argv[optind][1] != '\0') { if (argv[optind][1] == '-' && argv[optind][2] == '\0') double_dash = optind; /* quit outer loop after getopt */ |