This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: sendfile
- From: Bruno Haible <bruno at clisp dot org>
- To: Christoph Hellwig <hch at lst dot de>
- Cc: libc-alpha at sources dot redhat dot com
- Date: Mon, 9 Sep 2002 13:15:58 +0200 (CEST)
- Subject: Re: sendfile
- References: <15657.32324.233973.21851@honolulu.ilog.fr><200208270832.g7R8WKh23780@dhcp187.sf.frob.com><15735.18687.31463.590071@honolulu.ilog.fr><20020905142554.A30324@lst.de>
Christoph Hellwig wrote:
> Linux sendfile isn't guarenteed to work on anything
Well the manpage gives some guarantees:
This call copies data between one file descriptor and
another. Either or both of these file descriptors may
refer to a socket. in_fd should be a file descriptor
opened for reading and out_fd should be a descriptor
opened for writing. ...
Presently the descriptor from which data is read cannot
correspond to a socket, it must correspond to a file which
supports mmap()-like operations.
and according to my reading of the 2.4 kernel the must-mmap-input
restriction is the only one.
> e.g. Linux 2.5-CURRENT sendfile works also only on sockets.
Then it's a regression in the kernel, features (2.4) > features (2.5).
Bruno