summaryrefslogtreecommitdiffstats
path: root/ncr-key-wrap.c
diff options
context:
space:
mode:
authorMiloslav Trmač <mitr@redhat.com>2010-07-09 08:13:41 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2010-07-19 09:25:17 +0200
commitbdaef75e5a9ff8454558b16c3bcbd06c3e588475 (patch)
treed24727759bd98212f7d6c0a7e01d7ede9faeeaf2 /ncr-key-wrap.c
parenta50f325fa89fe2e4b6dfeb1c76a2e23ddaad4b68 (diff)
downloadkernel-crypto-bdaef75e5a9ff8454558b16c3bcbd06c3e588475.tar.gz
kernel-crypto-bdaef75e5a9ff8454558b16c3bcbd06c3e588475.tar.xz
kernel-crypto-bdaef75e5a9ff8454558b16c3bcbd06c3e588475.zip
Fix error paths in ncr_key_wrap
Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
Diffstat (limited to 'ncr-key-wrap.c')
-rw-r--r--ncr-key-wrap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ncr-key-wrap.c b/ncr-key-wrap.c
index 5510436502a..3caa0c5e546 100644
--- a/ncr-key-wrap.c
+++ b/ncr-key-wrap.c
@@ -436,7 +436,8 @@ int ret;
if (!(wkey->flags & NCR_KEY_FLAG_WRAPPABLE)) {
err();
- return -EPERM;
+ ret = -EPERM;
+ goto fail;
}
ret = ncr_key_item_get_read( &key, key_lst, wrap.key.key);