diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-09-29 23:38:07 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-09-29 23:38:07 -0400 |
commit | 0d4911081ce201f3e44bc8b32ac0f862d1260332 (patch) | |
tree | e6071b5ec945d05c1083d375c40688b29460e97c /fs | |
parent | 77f890223338c890fc33972673d2bd3a53061570 (diff) | |
parent | 1fc8a117865b54590acd773a55fbac9221b018f0 (diff) |
Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2
* 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2:
ocfs2: Don't walk off the end of fast symlinks.
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ocfs2/symlink.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ocfs2/symlink.c b/fs/ocfs2/symlink.c index 32499d213fc4..9975457c981f 100644 --- a/fs/ocfs2/symlink.c +++ b/fs/ocfs2/symlink.c | |||
@@ -128,7 +128,7 @@ static void *ocfs2_fast_follow_link(struct dentry *dentry, | |||
128 | } | 128 | } |
129 | 129 | ||
130 | /* Fast symlinks can't be large */ | 130 | /* Fast symlinks can't be large */ |
131 | len = strlen(target); | 131 | len = strnlen(target, ocfs2_fast_symlink_chars(inode->i_sb)); |
132 | link = kzalloc(len + 1, GFP_NOFS); | 132 | link = kzalloc(len + 1, GFP_NOFS); |
133 | if (!link) { | 133 | if (!link) { |
134 | status = -ENOMEM; | 134 | status = -ENOMEM; |