lkml.org 
[lkml]   [2011]   [Dec]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH v2 0/2] vfs: truncate bug fixes
Date
When a file is opened with O_TRUNC or truncated with truncate()/ftruncate(),
and then closed, iversion is not updated. This patch uses ATTR_OPEN flag,
which is currently used to identify files opened with O_TRUNC,
as an indication to increment iversion.
Also it adds passing of this flag from do_sys_truncate and do_sys_ftruncate.
To reflect real meaning, ATTR_OPEN is suggested to be renamed to ATTR_TRUNC.

Dmitry Kasatkin (2):
vfs: iversion truncate bug fix
vfs: ATTR_OPEN rename

fs/attr.c | 3 +++
fs/fuse/dir.c | 4 ++--
fs/namei.c | 2 +-
fs/open.c | 5 +++--
include/linux/fs.h | 2 +-
5 files changed, 10 insertions(+), 6 deletions(-)

--
1.7.4.1



\
 
 \ /
  Last update: 2011-12-22 09:59    [W:0.076 / U:0.304 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site