Re: [PATCH v2 2/4] bundle: support fsck message configuration
- From
Patrick Steinhardt <ps@pks.im>
- Date
- Nov 27, 2024, 05:44 UTC
- Message-ID
- <Z0axyWrT8n8reQWl@pks.im>
- In-Reply-To
- <20241127005707.319881-3-jltobler@gmail.com>
On Tue, Nov 26, 2024 at 06:57:05PM -0600, Justin Tobler wrote:
Show 15 quoted lines
> diff --git a/bundle.c b/bundle.c
> index 485033ea3f..4e53ddfca2 100644
> --- a/bundle.c
> +++ b/bundle.c
> @@ -631,12 +631,12 @@ int unbundle(struct repository *r, struct bundle_header *header,
> struct unbundle_opts *opts)
> {
> struct child_process ip = CHILD_PROCESS_INIT;
> - enum verify_bundle_flags flags = 0;
> + struct unbundle_opts opts_fallback = { 0 };
>
> - if (opts)
> - flags = opts->flags;
> + if (!opts)
> + opts = &opts_fallback;Tiny nit: you could've introduced the fallback in the first commit already. Like this you first introduce the code pattern and then change it immediately in the subsequent commit.
Not worth a reroll though.
Show 9 quoted lines
> diff --git a/bundle.h b/bundle.h
> index 6a09cc7bfb..df17326b09 100644
> --- a/bundle.h
> +++ b/bundle.h
> @@ -41,6 +41,13 @@ int verify_bundle(struct repository *r, struct bundle_header *header,
>
> struct unbundle_opts {
> enum verify_bundle_flags flags;
> + /**Nit: s|/**/|/*|
Again, not worth a reroll from my point of view, also with the recent discussion at <877c8yti5n.fsf@iotcl.com> in mind where we basically went "We don't care about them".
Patrick