From mboxrd@z Thu Jan 1 00:00:00 1970 From: Al Viro Subject: Re: [RFC] st_nlink after rmdir() and rename() Date: Thu, 3 Mar 2011 04:42:42 +0000 Message-ID: <20110303044242.GJ22723@ZenIV.linux.org.uk> References: <20110303032454.GI22723@ZenIV.linux.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org To: Linus Torvalds Return-path: Content-Disposition: inline In-Reply-To: <20110303032454.GI22723@ZenIV.linux.org.uk> Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On Thu, Mar 03, 2011 at 03:24:54AM +0000, Al Viro wrote: > 0 0: ext*, xfs, jfs, reiserfs, ocfs2, gfs2, nilfs, exofs, udf, ubifs, > minix, sysv, ufs, msdos, vfat, hfs+ > 0 1: ramfs, shmem, hugetlbfs, jffs2, omfs, hfs[*], apparently nfs as well > [*] yes, different from hfs+; the code is clearly broken, since it simply > does unlink() on target, without even verifying that it's empty. And > yes, it's trivial fs corruption... Actually, hfs turns out to be 0 0 as well; it *is* broken (lacks check for target being empty), but when the target is empty it's doing the right thing. jffs2 and ramfs-based ones do 0 1 - confirmed by direct experiment.