[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20080508165247.GC13914@infradead.org>
Date: Thu, 8 May 2008 12:52:47 -0400
From: Christoph Hellwig <hch@...radead.org>
To: Miklos Szeredi <miklos@...redi.hu>
Cc: akpm@...ux-foundation.org, hch@...radead.org,
viro@...IV.linux.org.uk, linux-fsdevel@...r.kernel.org,
linux-kernel@...r.kernel.org,
Mikulas Patocka <mikulas@...ax.karlin.mff.cuni.cz>
Subject: Re: [patch 06/24] hpfs: dont call notify_change
On Tue, May 06, 2008 at 11:13:33AM +0200, Miklos Szeredi wrote:
> From: Miklos Szeredi <mszeredi@...e.cz>
>
> hpfs_unlink() calls notify_change() to truncate the file before
> deleting. Replace with explicit call to hpfs_notify_change().
>
> This is equivalent, except that:
> - security_inode_setattr() is not called before hpfs_notify_change()
> - fsnotify_change() is not called after hpfs_notify_change()
>
> The truncation is just an implementation detail, so both the security
> check and the notification are unnecessary.
>
> Possibly even the ctime modification is wrong?
This code is rahter scary, as we'd lost the content without the file
when the second remove_dirent attempt fails. Because of that we should
at least keep the ctime change so an app can know the file was touched.
Again, looks correct but I'm not convinced about all these changes.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists