From: Michael Halcrow Date: Fri, 3 Nov 2006 06:06:56 +0000 (-0800) Subject: [PATCH] eCryptfs: Fix pointer deref X-Git-Tag: v2.6.19-rc5~60 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7bd473fcc217adec000f213e8864bf9a161d57e1;p=linux-2.6 [PATCH] eCryptfs: Fix pointer deref I missed a pointer dereference in this kmalloc result check. Signed-off-by: Michael Halcrow Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/ecryptfs/crypto.c b/fs/ecryptfs/crypto.c index f49f105394..136175a693 100644 --- a/fs/ecryptfs/crypto.c +++ b/fs/ecryptfs/crypto.c @@ -134,7 +134,7 @@ int ecryptfs_crypto_api_algify_cipher_name(char **algified_name, algified_name_len = (chaining_modifier_len + cipher_name_len + 3); (*algified_name) = kmalloc(algified_name_len, GFP_KERNEL); - if (!(algified_name)) { + if (!(*algified_name)) { rc = -ENOMEM; goto out; }