OSDN Git Service

Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
authorLinus Torvalds <torvalds@linux-foundation.org>
Wed, 31 Dec 2014 17:16:17 +0000 (09:16 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 31 Dec 2014 17:16:17 +0000 (09:16 -0800)
Pull crypto fix from Herbert Xu:
 "Fix a use-after-free crash in the user-space crypto API"

* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
  crypto: af_alg - fix backlog handling

crypto/af_alg.c

index 1fa7bc3..4665b79 100644 (file)
@@ -455,6 +455,9 @@ void af_alg_complete(struct crypto_async_request *req, int err)
 {
        struct af_alg_completion *completion = req->data;
 
+       if (err == -EINPROGRESS)
+               return;
+
        completion->err = err;
        complete(&completion->completion);
 }