可以使用 sendfile() linux 系统调用将文件的一部分从一个映射文件发送到另一个映射文件吗?
最佳答案
来自 sendfile(2)
:
Presently (Linux 2.6.9): in_fd, must correspond to a file which supports mmap()-like operations (i.e., it cannot be a socket); and out_fd must refer to a socket.
所以看起来答案是否定的。
编辑
我想我现在明白你在找什么了。查看splice(2)
.
关于linux - sendfile() 在两个映射文件上的用法 (linux),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2538653/