2 ms·
In the past I've found that sendfile is not portable. FreeBSD and Mac OS X require the file that is being sent be a regular file[0] while Linux will take any fi
by jonhohle 11y ago
In the past I've found that sendfile is not portable. FreeBSD and Mac OS X require the file that is being sent be a regular file[0] while Linux will take any file descriptor[1]. That being said, I can't imagine what benefit memmapping would have in the context over the file system page cache.
0 - https://www.freebsd.org/cgi/man.cgi?query=sendfile&sektion=2 https://www.freebsd.org/cgi/man.cgi?query=sendfile&sektion=2
1 - http://linux.die.net/man/2/sendfile http://linux.die.net/man/2/sendfile