lkml.org 
[lkml]   [2008]   [Oct]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: splice vs O_APPEND


On Thu, 9 Oct 2008, Miklos Szeredi wrote:
>
> We know that nobody is currently relying on O_APPEND semantics with
> splice, so this should be OK.

Having now realized that apparently you can't rely on O_APPEND for
anything but plain write _anyway_ (ie pwrite shouldn't honor it), I'm
going to drop this thing as "let's think about it more".

Maybe the right thing to do is to just say that O_APPEND (and IS_APPEND)
is really not as reliable as people might expect, and just say that the
only thing it affects is a plain write() system call.

Of course, I think POSIX is crazy, and we probably _should_ always honor
O_APPEND, and returning -EINVAL is the right thing for both pwrite and
splice, but this is all a murkier issue than it looked like originally,
and any possible "security" implications are dubious in that you cannot
really depend on O_APPEND/IS_APPEND anyway.

Linus


\
 
 \ /
  Last update: 2008-10-09 21:25    [W:0.195 / U:0.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site