Subject: Re: [PATCH v6] fast-(import|export): improve on commit signature output format

From: Junio C Hamano <[email-masked]>
Date: Wed, 09 Jul 2025 16:14:20 -0700

Christian Couder <[email-masked]> writes:

> +static void parse_one_signature(struct signature_data *sig, const char *v)
> +{
> +	char *args = xstrdup(v); /* Will be freed when sig->hash_algo is freed */
> +	char *space = strchr(args, ' ');
> +
> +	if (!space)
> +		die("Expected gpgsig format: 'gpgsig <hash-algo> <signature-format>', "
> +		    "got 'gpgsig %s'", args);
> +	*space = '\0';
> +
> +	sig->hash_algo = args;
> +	sig->sig_format = space + 1;

This is minor, but as I already said in the discussion of the
previous round, let me remind readers.

I think "*space++ = '\0'" followed by "->sig_format = space", as you
wrote originally, was easier to follow.  If I were doing this 6th
iteration, I would have kept that part of the code around here, but
would have renamed "space" to a more generic "cp" (very often used
in this codebase to stand for a character pointer).

Will replace and requeue (unless you have v7 before my tomorrow's
integration cycle, in which case this iteration may be skipped).

Thanks.