On 26/12/01 11:58AM, Patrick Steinhardt wrote:
> On Mon, Nov 30, 2026 at 03:54:57PM -0600, Justin Tobler wrote:
> > diff --git a/builtin/multi-pack-index.c b/builtin/multi-pack-index.c > > index c48212290cf8..1a27d523c7ab 100644 > > --- a/builtin/multi-pack-index.c > > +++ b/builtin/multi-pack-index.c > > @@ -80,7 +80,7 @@ static int parse_object_dir(const struct option *opt, const char *arg, > > char **value = opt->value; > > free(*value); > > if (unset) > > - *value = xstrdup(the_repository->objects->source->path); > > + *value = NULL; > > else > > *value = real_pathdup(arg, 1); > > return 0;
> > Makes me wonder whether we could avoid allocating the value altogether > and just assign the static string?
Ya, now that the option value is only set here, it should be fine to stop allocating the string. Will update in the next version. -Justin