diff options
author | Yan Zheng | 2008-02-19 17:41:02 +0100 |
---|---|---|
committer | Chris Mason | 2008-09-25 17:04:00 +0200 |
commit | 5e591a0703bc03047d37938586f97fd8ca960c08 (patch) | |
tree | 010c83864a48a34c78f9697bb0ab34d8a0fda4ba /fs/btrfs/inode.c | |
parent | Btrfs: Properly clear dirty and delalloc extent bits while preparing the file... (diff) | |
download | kernel-qcow2-linux-5e591a0703bc03047d37938586f97fd8ca960c08.tar.gz kernel-qcow2-linux-5e591a0703bc03047d37938586f97fd8ca960c08.tar.xz kernel-qcow2-linux-5e591a0703bc03047d37938586f97fd8ca960c08.zip |
Btrfs: Fix looping on readdir of the subvol roots
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 913ab128eee1..3e79572a5cb1 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -1465,7 +1465,10 @@ read_dir_items: di = (struct btrfs_dir_item *)((char *)di + di_len); } } - filp->f_pos = INT_LIMIT(typeof(filp->f_pos)); + if (key_type == BTRFS_DIR_INDEX_KEY) + filp->f_pos = INT_LIMIT(typeof(filp->f_pos)); + else + filp->f_pos++; nopos: ret = 0; err: |