Patch "crypto: essiv - remove redundant null pointer check before kfree" has been added to the 5.4-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    crypto: essiv - remove redundant null pointer check before kfree

to the 5.4-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     crypto-essiv-remove-redundant-null-pointer-check-bef.patch
and it can be found in the queue-5.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit b311c864e5e6cb849a3e78398333dca44e41f7e8
Author: Chen Wandun <chenwandun@xxxxxxxxxx>
Date:   Sat Nov 16 14:51:00 2019 +0800

    crypto: essiv - remove redundant null pointer check before kfree
    
    [ Upstream commit e18036da5c23530994faf7243b592e581f1efed2 ]
    
    kfree has taken null pointer check into account. so it is safe to
    remove the unnecessary check.
    
    Signed-off-by: Chen Wandun <chenwandun@xxxxxxxxxx>
    Signed-off-by: Herbert Xu <herbert@xxxxxxxxxxxxxxxxxxx>
    Stable-dep-of: b5a772adf45a ("crypto: essiv - Handle EBUSY correctly")
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/crypto/essiv.c b/crypto/essiv.c
index a8befc8fb06ed..3d3f9d7f607ca 100644
--- a/crypto/essiv.c
+++ b/crypto/essiv.c
@@ -188,8 +188,7 @@ static void essiv_aead_done(struct crypto_async_request *areq, int err)
 	struct aead_request *req = areq->data;
 	struct essiv_aead_request_ctx *rctx = aead_request_ctx(req);
 
-	if (rctx->assoc)
-		kfree(rctx->assoc);
+	kfree(rctx->assoc);
 	aead_request_complete(req, err);
 }
 



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux