diff options
| author | Junio C Hamano <gitster@pobox.com> | 2021-09-22 17:11:09 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2021-09-22 17:11:09 -0700 |
| commit | 6295f87b5f46fcb1037eb12e81afaf0490a00922 (patch) | |
| tree | b57cca00fffcb5ce6ff263685794cdbd0c54e819 /builtin/grep.c | |
| parent | 99c99ed8259bf070cd8ae7b51a94904b7cf5c161 (diff) | |
| parent | 10a0d6ae64ad4fec12ab2c1ed13d1791dde60371 (diff) | |
| download | git-6295f87b5f46fcb1037eb12e81afaf0490a00922.tar.gz | |
Merge branch 'jt/add-submodule-odb-clean-up' into jt/no-abuse-alternate-odb-for-submodules
* jt/add-submodule-odb-clean-up:
revision: remove "submodule" from opt struct
repository: support unabsorbed in repo_submodule_init
submodule: remove unnecessary unabsorbed fallback
Diffstat (limited to 'builtin/grep.c')
| -rw-r--r-- | builtin/grep.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/builtin/grep.c b/builtin/grep.c index 51278b01fa..8af5249a7b 100644 --- a/builtin/grep.c +++ b/builtin/grep.c @@ -433,17 +433,14 @@ static int grep_submodule(struct grep_opt *opt, { struct repository *subrepo; struct repository *superproject = opt->repo; - const struct submodule *sub; struct grep_opt subopt; int hit = 0; - sub = submodule_from_path(superproject, null_oid(), path); - if (!is_submodule_active(superproject, path)) return 0; subrepo = xmalloc(sizeof(*subrepo)); - if (repo_submodule_init(subrepo, superproject, sub)) { + if (repo_submodule_init(subrepo, superproject, path, null_oid())) { free(subrepo); return 0; } |
