]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
ext4: Fix duplicate entries returned from getdents() system call
authorTheodore Ts'o <tytso@mit.edu>
Sat, 25 Oct 2008 15:39:08 +0000 (11:39 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 26 Oct 2008 02:37:55 +0000 (22:37 -0400)
commit3c37fc86d20fe35be656f070997d62f75c2e4874
treeeb9593356a2aa3233ab8f198f044e81413423cde
parent8c9fa93d51123c5540762b1a9e1919d6f9c4af7c
ext4: Fix duplicate entries returned from getdents() system call

Fix a regression caused by commit d0156417, "ext4: fix ext4_dx_readdir
hash collision handling", where deleting files in a large directory
(requiring more than one getdents system call), results in some
filenames being returned twice.  This was caused by a failure to
update info->curr_hash and info->curr_minor_hash, so that if the
directory had gotten modified since the last getdents() system call
(as would be the case if the user is running "rm -r" or "git clean"),
a directory entry would get returned twice to the userspace.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
This patch fixes the bug reported by Markus Trippelsdorf at:
http://bugzilla.kernel.org/show_bug.cgi?id=11844

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Tested-by: Markus Trippelsdorf <markus@trippelsdorf.de>
fs/ext4/dir.c