crypto: ixp4xx - Fix error handling path in 'aead_perform()'
authorHerbert Xu <herbert@gondor.apana.org.au>
Wed, 2 Aug 2017 08:40:47 +0000 (16:40 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 9 Aug 2017 12:01:33 +0000 (20:01 +0800)
commit28389575a8cf933a5f3c378556b9f4d3cce0efd2
treea5279edab102a586cda55f12c628c8455d9c76ab
parent60c4081ec4195389f4fa1fce83eaad5e4b948748
crypto: ixp4xx - Fix error handling path in 'aead_perform()'

In commit 0f987e25cb8a, the source processing has been moved in front of
the destination processing, but the error handling path has not been
modified accordingly.
Free resources in the correct order to avoid some leaks.

Cc: <stable@vger.kernel.org>
Fixes: 0f987e25cb8a ("crypto: ixp4xx - Fix false lastlen uninitialised warning")
Reported-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
drivers/crypto/ixp4xx_crypto.c