diff options
Diffstat (limited to 'fs/9p/vfs_dir.c')
-rw-r--r-- | fs/9p/vfs_dir.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/9p/vfs_dir.c b/fs/9p/vfs_dir.c index 76c3b1ab6361..5cc00e56206e 100644 --- a/fs/9p/vfs_dir.c +++ b/fs/9p/vfs_dir.c @@ -138,6 +138,8 @@ static int v9fs_dir_readdir(struct file *file, struct dir_context *ctx) &err); if (err) return err; + if (n == 0) + return 0; rdir->head = 0; rdir->tail = n; |