Re: [PATCH 2/2] object-file: retry linking file into place when occluding file vanishes
- From
Patrick Steinhardt <ps@pks.im>
- Date
- Jan 6, 2025, 11:11 UTC
- Message-ID
- <Z3u6c1UVQyZuHLdk@pks.im>
- In-Reply-To
- <20250103195942.GA3212696@coredump.intra.peff.net>
On Fri, Jan 03, 2025 at 02:59:42PM -0500, Jeff King wrote:
Show 15 quoted lines
> On Fri, Jan 03, 2025 at 02:40:58PM -0500, Jeff King wrote: > > > I suspect there's a way to write this as a loop that would be more > > structured, but it would be a bigger refactor. Bonus points if it also > > get rid of the try_rename goto, too. ;) > > > > I'm OK punting on that, though. > > For fun, here's a version without any goto's in it, that should behave > the same. But it would be very easy to miss a case. So I don't know if > it is worth the regression risk, and I don't blame you if you delete > this message without looking carefully. ;) > > Diff is kind of hard to read, so you may want to apply (on top of your > patches) and just look at the post-image.
Thanks. For now though I think I prefer to go with the simpler diff that uses goto, as it feels less risky close to v2.48. We can still refactor this in the next release cycle.
Patrick