summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Klinghed <the_jk@yahoo.com>2017-07-26 23:49:42 +0200
committerJoel Klinghed <the_jk@yahoo.com>2017-07-26 23:49:42 +0200
commitb167e5e3825f61373c612f301bc227105e0eb5e4 (patch)
treee7798f893f8e0881449e72197ec3967db045dda1
parent51eb2a97303491ccbf446fd13c7dbed5bf6f9952 (diff)
Cleanup timeouts in proxy when freeing
-rw-r--r--src/proxy.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/proxy.cc b/src/proxy.cc
index 522454a..05a53bb 100644
--- a/src/proxy.cc
+++ b/src/proxy.cc
@@ -282,6 +282,13 @@ public:
close_monitor(it.index());
}
+ if (timeout_) {
+ looper_->cancel(timeout_);
+ }
+ if (new_timeout_) {
+ looper_->cancel(new_timeout_);
+ }
+
if (accept_socket_) {
looper_->remove(accept_socket_.get());
}