diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-11-06 15:50:21 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-11-06 15:50:21 +0900 |
commit | a29b8bcf624006cf66abe129c01c932ec75df9f7 (patch) | |
tree | f0b2fe07b7913d36e9151fc995aa3a31e3ffae65 /revision.c | |
parent | 8ac6990b8712cb7c44dfc4ff8d9e99b5ec55b01d (diff) | |
parent | 669b1d2aaec73ba762bf566078308075886ca208 (diff) | |
download | git-a29b8bcf624006cf66abe129c01c932ec75df9f7.tar.gz |
Merge branch 'md/exclude-promisor-objects-fix'
Operations on promisor objects make sense in the context of only a
small subset of the commands that internally use the revisions
machinery, but the "--exclude-promisor-objects" option were taken
and led to nonsense results by commands like "log", to which it
didn't make much sense. This has been corrected.
* md/exclude-promisor-objects-fix:
exclude-promisor-objects: declare when option is allowed
Documentation/git-log.txt: do not show --exclude-promisor-objects
Diffstat (limited to 'revision.c')
-rw-r--r-- | revision.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/revision.c b/revision.c index a1ddb9e11c..28fb2a70cd 100644 --- a/revision.c +++ b/revision.c @@ -2138,7 +2138,8 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg revs->limited = 1; } else if (!strcmp(arg, "--ignore-missing")) { revs->ignore_missing = 1; - } else if (!strcmp(arg, "--exclude-promisor-objects")) { + } else if (revs->allow_exclude_promisor_objects_opt && + !strcmp(arg, "--exclude-promisor-objects")) { if (fetch_if_missing) BUG("exclude_promisor_objects can only be used when fetch_if_missing is 0"); revs->exclude_promisor_objects = 1; |