Skip to content

Commit 142e9f4

Browse files
stefanbellergitster
authored andcommitted
submodule: don't add submodule as odb for push
In push_submodule(), because we do not actually need access to objects in the submodule, do not invoke add_submodule_odb(). (for_each_remote_ref_submodule() does not require access to those objects, and the actual push is done by spawning another process, which handles object access by itself.) This code of push_submodule() is exercised in t5531 and continues to work, showing that the submodule odbc is not needed. Signed-off-by: Stefan Beller <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 605f0ec commit 142e9f4

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

submodule.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1023,9 +1023,6 @@ static int push_submodule(const char *path,
10231023
const struct string_list *push_options,
10241024
int dry_run)
10251025
{
1026-
if (add_submodule_odb(path))
1027-
return 1;
1028-
10291026
if (for_each_remote_ref_submodule(path, has_remote, NULL) > 0) {
10301027
struct child_process cp = CHILD_PROCESS_INIT;
10311028
argv_array_push(&cp.args, "push");

0 commit comments

Comments
 (0)