summaryrefslogtreecommitdiff
path: root/fs/jffs2/jffs2_1pass.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/jffs2/jffs2_1pass.c')
-rw-r--r--fs/jffs2/jffs2_1pass.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/jffs2/jffs2_1pass.c b/fs/jffs2/jffs2_1pass.c
index b1d6470219..2e569ff59b 100644
--- a/fs/jffs2/jffs2_1pass.c
+++ b/fs/jffs2/jffs2_1pass.c
@@ -719,6 +719,12 @@ jffs2_1pass_read_inode(struct b_lists *pL, u32 inode, char *dest)
}
put_fl_mem(jNode, pL->readbuf);
}
+ /*
+ * If no destination is provided, we are done.
+ * Just return the total size.
+ */
+ if (!dest)
+ return totalSize;
#endif
for (b = pL->frag.listHead; b != NULL; b = b->next) {