From b214a9178d368d67e12ea65159c5b6de7b5098c4 Mon Sep 17 00:00:00 2001 From: Martijn Otto Date: Mon, 7 Sep 2015 14:18:40 +0200 Subject: [PATCH] Fix delay when disconnecting from rabbit --- include/connection.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/connection.h b/include/connection.h index 554a3a6..913bf25 100644 --- a/include/connection.h +++ b/include/connection.h @@ -216,6 +216,10 @@ class Connection : private ::AMQP::ConnectionHandler */ void onClosed(::AMQP::Connection *connection) override { + // no longer need the socket or the input + _socket.reset(); + _input.reset(); + // send to the handler if (_handler) _handler->onClosed(this); }