summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/nfs/dir.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c
index 42e66e961d73..353f47c31b1d 100644
--- a/fs/nfs/dir.c
+++ b/fs/nfs/dir.c
@@ -763,13 +763,14 @@ int uncached_readdir(nfs_readdir_descriptor_t *desc, void *dirent,
goto out;
}
+ desc->page_index = 0;
+ desc->page = page;
+
if (nfs_readdir_xdr_to_array(desc, page, inode) == -1) {
status = -EIO;
goto out_release;
}
- desc->page_index = 0;
- desc->page = page;
status = nfs_do_filldir(desc, dirent, filldir);
out: