Subject: Re: [PATCH v3 2/4] remote: use remote_state parameter internally

From: Junio C Hamano <[email-masked]>
Date: Wed, 20 Oct 2021 12:45:27 -0700

Glen Choo <[email-masked]> writes:

> Introduce a struct remote_state member to structs that need to
> 'remember' their remote_state. Without changing external-facing
> functions, replace the_repository->remote_state internally by using the
> remote_state member where it is applicable i.e. when a function accepts
> a struct that depends on the remote_state. If it is not applicable, add
> a struct remote_state parameter instead.
>
> As a result, external-facing functions are still tied to the_repository,
> but most static functions no longer reference
> the_repository->remote_state. The exceptions are those that are used in
> a way that depends on external-facing functions e.g. the callbacks to
> remote_get_1().
>
> Signed-off-by: Glen Choo <[email-masked]>
> ---
>  remote.c | 153 ++++++++++++++++++++++++++-----------------------------
>  remote.h |  10 ++++
>  2 files changed, 81 insertions(+), 82 deletions(-)

This made my "git push" to k.org and other places over ssh segfault
when their tip and what I am attempting to push are identical.  I
haven't spent more time than just to bisect the history down to
identify this commit as the possible culprit.