aboutsummaryrefslogtreecommitdiffstats
path: root/fs/udf/symlink.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/udf/symlink.c')
-rw-r--r--fs/udf/symlink.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/udf/symlink.c b/fs/udf/symlink.c
index e6f933dd6a7b..6ec99221e50c 100644
--- a/fs/udf/symlink.c
+++ b/fs/udf/symlink.c
@@ -33,7 +33,8 @@
33#include <linux/buffer_head.h> 33#include <linux/buffer_head.h>
34#include "udf_i.h" 34#include "udf_i.h"
35 35
36static void udf_pc_to_char(struct super_block *sb, char *from, int fromlen, char *to) 36static void udf_pc_to_char(struct super_block *sb, char *from, int fromlen,
37 char *to)
37{ 38{
38 struct pathComponent *pc; 39 struct pathComponent *pc;
39 int elen = 0; 40 int elen = 0;
@@ -78,10 +79,12 @@ static int udf_symlink_filler(struct file *file, struct page *page)
78 char *symlink; 79 char *symlink;
79 int err = -EIO; 80 int err = -EIO;
80 char *p = kmap(page); 81 char *p = kmap(page);
82 struct udf_inode_info *iinfo;
81 83
82 lock_kernel(); 84 lock_kernel();
83 if (UDF_I_ALLOCTYPE(inode) == ICBTAG_FLAG_AD_IN_ICB) { 85 iinfo = UDF_I(inode);
84 symlink = UDF_I_DATA(inode) + UDF_I_LENEATTR(inode); 86 if (iinfo->i_alloc_type == ICBTAG_FLAG_AD_IN_ICB) {
87 symlink = iinfo->i_ext.i_data + iinfo->i_lenEAttr;
85 } else { 88 } else {
86 bh = sb_bread(inode->i_sb, udf_block_map(inode, 0)); 89 bh = sb_bread(inode->i_sb, udf_block_map(inode, 0));
87 90