diff options
author | Miloslav Trmač <mitr@redhat.com> | 2010-07-20 02:27:57 +0200 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2010-07-21 20:13:48 +0200 |
commit | 619da468b62aed1c15fd81a4f630bcbb7c12dd7d (patch) | |
tree | 1b3635bec8071733178437a76fe8e73fd53086b9 /cryptodev_cipher.c | |
parent | 15d18ae53061d716a892adb04d65baa9c6e7fbf1 (diff) | |
download | cryptodev-linux-619da468b62aed1c15fd81a4f630bcbb7c12dd7d.tar.gz cryptodev-linux-619da468b62aed1c15fd81a4f630bcbb7c12dd7d.tar.xz cryptodev-linux-619da468b62aed1c15fd81a4f630bcbb7c12dd7d.zip |
Fix error handling in cryptodev_hash_init
Diffstat (limited to 'cryptodev_cipher.c')
-rw-r--r-- | cryptodev_cipher.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cryptodev_cipher.c b/cryptodev_cipher.c index 05e6db3..fa5aab2 100644 --- a/cryptodev_cipher.c +++ b/cryptodev_cipher.c @@ -262,12 +262,14 @@ int ret; if (unlikely(ret)) { dprintk(0,KERN_ERR, "error in crypto_hash_init()\n"); - goto error; + goto error_request; } hdata->init = 1; return 0; +error_request: + ahash_request_free(hdata->async.request); error: kfree(hdata->async.result); crypto_free_ahash(hdata->async.s); |