diff options
author | Nick Mathewson <nickm@torproject.org> | 2004-10-16 20:38:57 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2004-10-16 20:38:57 +0000 |
commit | a42adce3628c9b82c91ff21e85c6a2d4fbcefc13 (patch) | |
tree | b7f04f7a405e5638f21ad1fd86d77e216e517d75 /src/common/crypto.c | |
parent | b0afd91afec362e3edc58d1928d2a63bcb3097e8 (diff) | |
download | tor-a42adce3628c9b82c91ff21e85c6a2d4fbcefc13.tar.gz tor-a42adce3628c9b82c91ff21e85c6a2d4fbcefc13.zip |
fix memory leak in router.c; start relying on NULL==(zero bytes)
svn:r2538
Diffstat (limited to 'src/common/crypto.c')
-rw-r--r-- | src/common/crypto.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/common/crypto.c b/src/common/crypto.c index 7826512058..651822254c 100644 --- a/src/common/crypto.c +++ b/src/common/crypto.c @@ -1200,8 +1200,7 @@ crypto_dh_env_t *crypto_dh_new() if (!dh_param_p) init_dh_param(); - res = tor_malloc(sizeof(crypto_dh_env_t)); - res->dh = NULL; + res = tor_malloc_zero(sizeof(crypto_dh_env_t)); if (!(res->dh = DH_new())) goto err; |