Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 4180
b: refs/heads/master
c: a61cc44
h: refs/heads/master
v: v3
  • Loading branch information
Jesper Juhl authored and David S. Miller committed Jul 6, 2005
1 parent ec480e2 commit 35121e5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 476df259cd577e20379b02a7f7ffd086ea925a83
refs/heads/master: a61cc44812ff94793987bf43b70a3d9bc64a6820
12 changes: 10 additions & 2 deletions trunk/crypto/api.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
* any later version.
*
*/

#include <linux/compiler.h>
#include <linux/init.h>
#include <linux/crypto.h>
#include <linux/errno.h>
Expand Down Expand Up @@ -189,8 +191,14 @@ struct crypto_tfm *crypto_alloc_tfm(const char *name, u32 flags)

void crypto_free_tfm(struct crypto_tfm *tfm)
{
struct crypto_alg *alg = tfm->__crt_alg;
int size = sizeof(*tfm) + alg->cra_ctxsize;
struct crypto_alg *alg;
int size;

if (unlikely(!tfm))
return;

alg = tfm->__crt_alg;
size = sizeof(*tfm) + alg->cra_ctxsize;

crypto_exit_ops(tfm);
crypto_alg_put(alg);
Expand Down

0 comments on commit 35121e5

Please sign in to comment.