Browse Source

we were leaking some memory every time the client changes IPs

svn:r5165
Roger Dingledine 20 years ago
parent
commit
e28c31ebce
1 changed files with 2 additions and 0 deletions
  1. 2 0
      src/or/router.c

+ 2 - 0
src/or/router.c

@@ -95,6 +95,8 @@ get_onion_key_set_at(void)
 void
 set_identity_key(crypto_pk_env_t *k)
 {
+  if (identitykey)
+    crypto_free_pk_env(identitykey);
   identitykey = k;
 }