How does sendfile() operate internally?
I want to know whether the sendfile() function in Linux works by implementing splice() function or not, for the purpose of copying the contents of one file to another.
If I write the following:
sendfile(source,dest,NULL,block);
Or this:
splice(source,0,pipefd[1],NULL,block,SPLICE_F_MORE|SPLICE_F_MOVE);
splice(pipefd[0],NULL,dest,0,block,SPLICE_F_MORE|SPLICE_F_MOVE);
Will both methods work in a similar way internally?
Does sendfile() also make use of pipes?
|