Skip to content

Commit 5fa7dad

Browse files
horiagherbertx
authored andcommitted
crypto: talitos - avoid memleak in talitos_alg_alloc()
Cc: <stable@vger.kernel.org> # 3.2+ Fixes: 1d11911 ("crypto: talitos - fix warning: 'alg' may be used uninitialized in this function") Signed-off-by: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
1 parent f7ead7b commit 5fa7dad

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

‎drivers/crypto/talitos.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2813,6 +2813,7 @@ static struct talitos_crypto_alg *talitos_alg_alloc(struct device *dev,
28132813
break;
28142814
default:
28152815
dev_err(dev, "unknown algorithm type %d\n", t_alg->algt.type);
2816+
kfree(t_alg);
28162817
return ERR_PTR(-EINVAL);
28172818
}
28182819

0 commit comments

Comments
 (0)