Skip to content

Commit 380ebab

Browse files
bk2204gitster
authored andcommitted
fetch-pack: clear alternate shallow in one more place
The previous one did not clear the variable in one codepath, but we should aim to be complete. Signed-off-by: brian m. carlson <[email protected]> [jc: made a reroll into incremental, as the previous one already is in the next branch] Signed-off-by: Junio C Hamano <[email protected]>
1 parent 23311f3 commit 380ebab

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

fetch-pack.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1272,6 +1272,8 @@ static void receive_shallow_info(struct fetch_pack_args *args,
12721272
setup_alternate_shallow(&shallow_lock, &alternate_shallow_file,
12731273
NULL);
12741274
args->deepen = 1;
1275+
} else {
1276+
alternate_shallow_file = NULL;
12751277
}
12761278
}
12771279

0 commit comments

Comments
 (0)