summaryrefslogtreecommitdiff
path: root/src/or/control.c
diff options
context:
space:
mode:
authorGeorge Kadianakis <desnacked@riseup.net>2013-08-14 17:16:06 +0300
committerNick Mathewson <nickm@torproject.org>2013-08-15 12:03:38 -0400
commitf549e4c36d0658b6255d3b9cf7c56131d4a37a57 (patch)
tree6cb52935cd32ebafab09cbe9999bf02cdc2b08cb /src/or/control.c
parent33c3e60a376291faed073dcfb6c9b8a0098572a0 (diff)
downloadtor-f549e4c36d0658b6255d3b9cf7c56131d4a37a57.tar.gz
tor-f549e4c36d0658b6255d3b9cf7c56131d4a37a57.zip
Write some free_all functions to free the auth. cookies.
We started allocating space for them on the heap in the previous commit. Conflicts: src/or/ext_orport.h
Diffstat (limited to 'src/or/control.c')
-rw-r--r--src/or/control.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/or/control.c b/src/or/control.c
index b6ba12702e..03b42af539 100644
--- a/src/or/control.c
+++ b/src/or/control.c
@@ -4750,3 +4750,11 @@ control_event_clients_seen(const char *controller_str)
"650 CLIENTS_SEEN %s\r\n", controller_str);
}
+/** Free any leftover allocated memory of the control.c subsystem. */
+void
+control_free_all(void)
+{
+ if (authentication_cookie) /* Free the auth cookie */
+ tor_free(authentication_cookie);
+}
+