summaryrefslogtreecommitdiff
path: root/crypto/Kconfig
diff options
context:
space:
mode:
authorJesper Juhl <juhl-lkml@dif.dk>2005-07-06 13:54:31 -0700
committerDavid S. Miller <davem@davemloft.net>2005-07-06 13:54:31 -0700
commit5129a9856d9dde77ccba6f3a17854a73dea5bff9 (patch)
treef7899e2969957ddc5847c9fff8d7ef3026c022f7 /crypto/Kconfig
parent88912b4fe0b6fd9b9fa82e573bf32c40aab562a3 (diff)
downloadlinux-crypto-5129a9856d9dde77ccba6f3a17854a73dea5bff9.tar.gz
linux-crypto-5129a9856d9dde77ccba6f3a17854a73dea5bff9.zip
[CRYPTO] Add null short circuit to crypto_free_tfm
As far as I'm aware there's a general concensus that functions that are responsible for freeing resources should be able to cope with being passed a NULL pointer. This makes sense as it removes the need for all callers to check for NULL, thus elliminating the bugs that happen when some forget (safer to just check centrally in the freeing function) and it also makes for smaller code all over due to the lack of all those NULL checks. This patch makes it safe to pass the crypto_free_tfm() function a NULL pointer. Once this patch is applied we can start removing the NULL checks from the callers. Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'crypto/Kconfig')
0 files changed, 0 insertions, 0 deletions