From cf8bc5773c27adf325d7bb1a90d290b213a57417 Mon Sep 17 00:00:00 2001 From: wdenk Date: Wed, 4 May 2005 23:50:54 +0000 Subject: Fix problem with symbolic links in JFFS2 code. --- fs/jffs2/jffs2_1pass.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'fs') diff --git a/fs/jffs2/jffs2_1pass.c b/fs/jffs2/jffs2_1pass.c index f753a6b70a..f3a9c53997 100644 --- a/fs/jffs2/jffs2_1pass.c +++ b/fs/jffs2/jffs2_1pass.c @@ -760,7 +760,11 @@ jffs2_1pass_list_inodes(struct b_lists * pL, u32 pino) if (jNode->ino == jDir->ino && jNode->version >= i_version) { if (i) put_fl_mem(i); - i = get_fl_mem(b2->offset, sizeof(*i), NULL); + + if (jDir->type == DT_LNK) + i = get_node_mem(b2->offset); + else + i = get_fl_mem(b2->offset, sizeof(*i), NULL); } b2 = b2->next; } -- cgit v1.2.1