summaryrefslogtreecommitdiffstats
path: root/ncr-key.c
diff options
context:
space:
mode:
Diffstat (limited to 'ncr-key.c')
-rw-r--r--ncr-key.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ncr-key.c b/ncr-key.c
index 79adf77..d4f32b1 100644
--- a/ncr-key.c
+++ b/ncr-key.c
@@ -186,9 +186,9 @@ int ncr_key_init(struct ncr_lists *lst, void __user* arg)
_ncr_key_item_put(key);
return -ENOMEM;
}
+ desc = key->desc;
mutex_unlock(&lst->key_idr_mutex);
- desc = key->desc;
ret = copy_to_user(arg, &desc, sizeof(desc));
if (unlikely(ret)) {
_ncr_key_remove(lst, desc);