diff options
Diffstat (limited to 'builtin-grep.c')
-rw-r--r-- | builtin-grep.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/builtin-grep.c b/builtin-grep.c index 2e7986cece..a8bec72f82 100644 --- a/builtin-grep.c +++ b/builtin-grep.c @@ -817,8 +817,12 @@ int cmd_grep(int argc, const char **argv, char **envp) } usage(builtin_grep_usage); } - if (!strcmp("--", arg)) + if (!strcmp("--", arg)) { + /* later processing wants to have this at argv[1] */ + argv--; + argc++; break; + } if (*arg == '-') usage(builtin_grep_usage); |