negotiator/skipping: avoid stack overflow
commit4654134976fd4d80ea664c159f798f21c7917d8c
authorJonathan Tan <jonathantanmy@google.com>
Tue, 25 Oct 2022 23:29:34 +0000 (25 16:29 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 26 Oct 2022 00:14:40 +0000 (25 17:14 -0700)
treea30ae251be8a8291989791ce4e985e9652e8b1f4
parent7d8dc5a1af9da32ac7454499f308db757eb19642
negotiator/skipping: avoid stack overflow

mark_common() in negotiator/skipping.c may overflow the stack due to
recursive function calls. Avoid this by instead recursing using a
heap-allocated data structure.

Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
negotiator/skipping.c