+29
−10
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
The function crypto_alg_match returns an algorithm without taking
any references on it. This means that the algorithm can be freed
at any time, therefore all users of crypto_alg_match are buggy.
This patch fixes this by taking a reference count on the algorithm
to prevent such races.
Signed-off-by:
Herbert Xu <herbert@gondor.apana.org.au>