Skip to content

Commit

Permalink
crypto: talitos - avoid memleak in talitos_alg_alloc()
Browse files Browse the repository at this point in the history
Cc: <[email protected]> # 3.2+
Fixes: 1d11911 ("crypto: talitos - fix warning: 'alg' may be used uninitialized in this function")
Signed-off-by: Horia Geanta <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
  • Loading branch information
horiag authored and herbertx committed May 13, 2015
1 parent f7ead7b commit 5fa7dad
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/crypto/talitos.c
Original file line number Diff line number Diff line change
Expand Up @@ -2813,6 +2813,7 @@ static struct talitos_crypto_alg *talitos_alg_alloc(struct device *dev,
break;
default:
dev_err(dev, "unknown algorithm type %d\n", t_alg->algt.type);
kfree(t_alg);
return ERR_PTR(-EINVAL);
}

Expand Down

0 comments on commit 5fa7dad

Please sign in to comment.