lkml.org 
[lkml]   [2004]   [May]   [10]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateMon, 10 May 2004 15:26:02 -0400
SubjectRe: [ANNOUNCEMENT PATCH COW] proof of concept impementation of cowlinks
FromJan Harkes <>
On Mon, May 10, 2004 at 05:53:59PM +0200, Jörn Engel wrote:
> A real problem is that copyfile() has all errno's from create(),
> sendfile() and unlink() combined, which doesn't make error handling in
> userspace easy.  "It could be this, that or another error" is the kind
> of mess I always hated about Windows, so I should try to do a little
> better.

Well, if you leave the create and unlink up to the application and
simply pass open filedescriptors to copyfile... But then it would be
equivalent to your new sendfile.

Copyfile can trivially be implemented in libc. I don't see why it would
have to be a system call. If a network filesystem wants to optimize the
file copying it could do this based on the sendfile data. If source and
destination are within the same filesystem and we're copying the whole
file starting at offset 0, send a copyfile RPC.

Jan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:03    [W:0.551 / U:0.010 seconds]
©2003-2008 Jasper Spaans