Re: [PATCH] pack-refs: use lockfile as everybody else does.
- From
Linus Torvalds <torvalds@osdl.org>
- Date
- Oct 5, 2006, 02:55 UTC
- Message-ID
- <Pine.LNX.4.64.0610041954480.3952@g5.osdl.org>
- In-Reply-To
- <7v7izhrc2v.fsf@assigned-by-dhcp.cox.net>
On Tue, 3 Oct 2006, Junio C Hamano wrote:
Show 5 quoted lines
> > Also I am not sure about the "fsync(fd); fclose(refs_file)" > sequence I did not touch with this patch. Doesn't stdio still > have stuff buffered when you run fsync()? Would adding fflush() > in between help?
Yes, there should be a fflush() there before the fsync.
Linus