Skip to content
Commit 59e96e65 authored by Al Viro's avatar Al Viro
Browse files

do_last(): don't bother with keeping got_write in FMODE_OPENED case



it's easier to drop it right after lookup_open() and regain if
needed (i.e. if we will need to truncate).  On the non-FMODE_OPENED
path we do that anyway.  In case of FMODE_CREATED we won't be
needing it.  And it's easier to prove correctness that way,
especially since the initial failure to get write access is not
always fatal; proving that we'll never end up truncating in that
case is rather convoluted.

Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent 3ad5615a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment