Date: Thu, 19 Apr 2007 09:19:36 +0200 From: Andre Oppermann <andre@freebsd.org> To: Pawel Jakub Dawidek <pjd@FreeBSD.org> Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern uipc_syscalls.c Message-ID: <46271808.7070105@freebsd.org> In-Reply-To: <200704190554.l3J5sjFk005073@repoman.freebsd.org> References: <200704190554.l3J5sjFk005073@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Pawel Jakub Dawidek wrote: > pjd 2007-04-19 05:54:45 UTC > > FreeBSD src repository > > Modified files: > sys/kern uipc_syscalls.c > Log: > Fix a bug in sendfile(2) when files larger than page size and nbytes=0. > When nbytes=0, sendfile(2) should use file size. Because of the bug, it > was sending half of a file. The bug is that 'off' variable can't be used > for size calculation, because it changes inside the loop, so we should > use uap->offset instead. Good catch! Thanks for finding and fixing this bug. There is a second bug that gets the accounting of the header wrong for which I've got a fix already in testing. -- Andre
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?46271808.7070105>