commit 299a78c5fed3447a450cea3d4f686c2140c7aaed Author: Nick Mathewson nickm@torproject.org Date: Fri Nov 12 20:21:50 2010 -0500
Make crypto_free_pk_env tolerate NULL arg in 0.2.1. Error-proofing against bug 988 backport --- src/common/crypto.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/src/common/crypto.c b/src/common/crypto.c index dffa2c7..c723c33 100644 --- a/src/common/crypto.c +++ b/src/common/crypto.c @@ -321,7 +321,8 @@ crypto_new_pk_env(void) void crypto_free_pk_env(crypto_pk_env_t *env) { - tor_assert(env); + if (!env) + return;
if (--env->refs > 0) return;
tor-commits@lists.torproject.org