diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-09 05:33:59 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-09 05:33:59 +0200 |
commit | f4ebc993759dc25dc3db6b6f1a13a23df8264d4b (patch) | |
tree | 666ba193b462ac1db51d58d908665b96b18752fe | |
parent | Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6 (diff) | |
parent | [CRYPTO] cryptomgr: Fix use after free (diff) | |
download | linux-f4ebc993759dc25dc3db6b6f1a13a23df8264d4b.tar.xz linux-f4ebc993759dc25dc3db6b6f1a13a23df8264d4b.zip |
Merge master.kernel.org:/pub/scm/linux/kernel/git/herbert/crypto-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/herbert/crypto-2.6:
[CRYPTO] cryptomgr: Fix use after free
-rw-r--r-- | crypto/cryptomgr.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/crypto/cryptomgr.c b/crypto/cryptomgr.c index 6958ea83ee44..e5fb7cca5107 100644 --- a/crypto/cryptomgr.c +++ b/crypto/cryptomgr.c @@ -24,8 +24,6 @@ #include "internal.h" struct cryptomgr_param { - struct task_struct *thread; - struct rtattr *tb[CRYPTOA_MAX]; struct { @@ -81,6 +79,7 @@ err: static int cryptomgr_schedule_probe(struct crypto_larval *larval) { + struct task_struct *thread; struct cryptomgr_param *param; const char *name = larval->alg.cra_name; const char *p; @@ -130,8 +129,8 @@ static int cryptomgr_schedule_probe(struct crypto_larval *larval) memcpy(param->larval.name, larval->alg.cra_name, CRYPTO_MAX_ALG_NAME); - param->thread = kthread_run(cryptomgr_probe, param, "cryptomgr"); - if (IS_ERR(param->thread)) + thread = kthread_run(cryptomgr_probe, param, "cryptomgr"); + if (IS_ERR(thread)) goto err_free_param; return NOTIFY_STOP; |