revision.c: put promisor option in specialized struct
Put the allow_exclude_promisor_objects flag in setup_revision_opt. When it was in rev_info, it was unclear when it was used, since rev_info is passed to functions that don't use the flag. This resulted in unnecessary setting of the flag in prune.c, so fix that as well. Signed-off-by: Matthew DeVore <matvore@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
669b1d2aae
commit
bbcde41a70
@ -357,6 +357,9 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
|
||||
{
|
||||
struct rev_info revs;
|
||||
struct rev_list_info info;
|
||||
struct setup_revision_opt s_r_opt = {
|
||||
.allow_exclude_promisor_objects = 1,
|
||||
};
|
||||
int i;
|
||||
int bisect_list = 0;
|
||||
int bisect_show_vars = 0;
|
||||
@ -370,7 +373,6 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
|
||||
git_config(git_default_config, NULL);
|
||||
init_revisions(&revs, prefix);
|
||||
revs.abbrev = DEFAULT_ABBREV;
|
||||
revs.allow_exclude_promisor_objects_opt = 1;
|
||||
revs.commit_format = CMIT_FMT_UNSPECIFIED;
|
||||
|
||||
/*
|
||||
@ -401,7 +403,7 @@ int cmd_rev_list(int argc, const char **argv, const char *prefix)
|
||||
}
|
||||
}
|
||||
|
||||
argc = setup_revisions(argc, argv, &revs, NULL);
|
||||
argc = setup_revisions(argc, argv, &revs, &s_r_opt);
|
||||
|
||||
memset(&info, 0, sizeof(info));
|
||||
info.revs = &revs;
|
||||
|
Reference in New Issue
Block a user