> If we are plumbing repo into ref stores, it makes sense to get rid of > the_repository in refs/files-backend.c and use ref_store.repo instead. > > Signed-off-by: Glen Choo <chooglen@xxxxxxxxxx> > --- > In [1], I made some changes to refs/files-backend.c to get rid of > the_repository and accept struct repository as a parameter instead. But, > if we're changing ref stores to contain their own repository, it makes > sense to use this new interface. > > I think the most natural place for this is this series. Let me know what > you think :) > > [1] https://lore.kernel.org/git/20210921232529.81811-2-chooglen@xxxxxxxxxx/ [snip] > @@ -1347,7 +1347,7 @@ static int rename_tmp_log(struct files_ref_store *refs, const char *newrefname) > return ret; > } > > -static int write_ref_to_lockfile(struct ref_lock *lock, > +static int write_ref_to_lockfile(struct repository *repo, struct ref_lock *lock, Ah sorry, I didn't see that you already did this. I don't think that it's natural to do it here - it's probably better to do it in another patch set that also verifies that there are no implicit references to the_repository.