summaryrefslogtreecommitdiffstats
path: root/fs/ext2/namei.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2015-05-02 10:02:46 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2015-05-10 22:18:21 -0400
commitcbe0fa3858cd638d1b540fe1279484bbd71489fb (patch)
tree10a66d9b95ead5154b5125dcfe60dcbf4d51a3ba /fs/ext2/namei.c
parent61ba64fc0768879a300599b011c176203bdf27d9 (diff)
downloadlinux-cbe0fa3858cd638d1b540fe1279484bbd71489fb.tar.bz2
ext2: use simple_follow_link()
Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ext2/namei.c')
-rw-r--r--fs/ext2/namei.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ext2/namei.c b/fs/ext2/namei.c
index 3e074a9ccbe6..13ec54a99c96 100644
--- a/fs/ext2/namei.c
+++ b/fs/ext2/namei.c
@@ -189,7 +189,8 @@ static int ext2_symlink (struct inode * dir, struct dentry * dentry,
} else {
/* fast symlink */
inode->i_op = &ext2_fast_symlink_inode_operations;
- memcpy((char*)(EXT2_I(inode)->i_data),symname,l);
+ inode->i_link = (char*)EXT2_I(inode)->i_data;
+ memcpy(inode->i_link, symname, l);
inode->i_size = l-1;
}
mark_inode_dirty(inode);