From: Junio C Hamano Date: Thu, 11 Jan 2007 21:02:13 GMT Subject: Re: tree corrupted on disk quota full Message-ID: <7vtzyx2s6i.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Linus Torvalds writes: > I personally think write_in_full() is totally mis-designed. If you are > ready to handle partial writes, you should use "xwrite()". If you're not > ready to handle partial writes, you should either use "write_or_die()", > _or_ you should expect a partial write to at least return an error code > (which is how "write_buffer()" works). > But that's not how write_in_full() actually works. Write-in-full does not > return an error for a partial write, it returns the partial size. > > Which is idiotic. It makes the function pointless. Just use xwrite() for > that. I agree 100% with the above reasoning.