From ec1037fcbc3c7a4c85f540a6b931d5e80cf25fd2 Mon Sep 17 00:00:00 2001 From: ridiculousfish Date: Mon, 26 Aug 2013 21:10:02 -0700 Subject: [PATCH] Fix bad error message for certain options. https://github.com/fish-shell/fish-shell/issues/979 --- wgetopt.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/wgetopt.cpp b/wgetopt.cpp index 8e114117b..08ccc3b14 100644 --- a/wgetopt.cpp +++ b/wgetopt.cpp @@ -638,6 +638,7 @@ _wgetopt_internal(int argc, wchar_t *const *argv, const wchar_t *optstring, cons fwprintf(stderr, _(L"%ls: Invalid option -- %lc\n"), argv[0], c); } woptopt = c; + woptind++; return '?'; } if (temp[1] == ':')