Btrfs: Force f_pos to the max when a readdir hits the end of the directory.
[deliverable/linux.git] / fs / btrfs / inode.c
index 16d3aef45d189a561fafa15700181b1bde39ae93..026bc9c4c90d37a0b6a766cf48e56102c432e8ea 100644 (file)
@@ -1430,7 +1430,7 @@ read_dir_items:
                        di = (struct btrfs_dir_item *)((char *)di + di_len);
                }
        }
-       filp->f_pos++;
+       filp->f_pos = INT_LIMIT(typeof(filp->f_pos));
 nopos:
        ret = 0;
 err:
This page took 0.025547 seconds and 5 git commands to generate.