As suggested by Junio, disallow the flags PARSE_OPT_KEEP_UNKNOWN and PARSE_OPT_STOP_AT_NON_OPTION to be turned on at the same time, as a value of an unknown option could be mistakenly classified as a non-option, stopping the parser early. E.g.: git cmd --known --unknown value arg0 arg1 The parser should have stopped at "arg0", but it already stops at "value". This patch makes parse_options() die if the two flags are used in combination. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com> |
||
|---|---|---|
| .. | ||
| .gitignore | ||
| api-allocation-growing.txt | ||
| api-builtin.txt | ||
| api-decorate.txt | ||
| api-diff.txt | ||
| api-directory-listing.txt | ||
| api-gitattributes.txt | ||
| api-grep.txt | ||
| api-hash.txt | ||
| api-history-graph.txt | ||
| api-in-core-index.txt | ||
| api-index-skel.txt | ||
| api-index.sh | ||
| api-lockfile.txt | ||
| api-object-access.txt | ||
| api-parse-options.txt | ||
| api-quote.txt | ||
| api-remote.txt | ||
| api-revision-walking.txt | ||
| api-run-command.txt | ||
| api-setup.txt | ||
| api-strbuf.txt | ||
| api-string-list.txt | ||
| api-tree-walking.txt | ||
| api-xdiff-interface.txt | ||
| pack-format.txt | ||
| pack-heuristics.txt | ||
| pack-protocol.txt | ||
| racy-git.txt | ||
| send-pack-pipeline.txt | ||
| shallow.txt | ||
| trivial-merge.txt | ||