diff --git a/include/amqpcpp/linux_tcp/tcpconnection.h b/include/amqpcpp/linux_tcp/tcpconnection.h index f7d3212..30e7c1b 100644 --- a/include/amqpcpp/linux_tcp/tcpconnection.h +++ b/include/amqpcpp/linux_tcp/tcpconnection.h @@ -5,7 +5,7 @@ * IO between the client application and the RabbitMQ server. * * @author Emiel Bruijntjes - * @copyright 2015 - 2016 Copernica BV + * @copyright 2015 - 2018 Copernica BV */ /** @@ -34,9 +34,7 @@ private: /** * The state of the TCP connection - this state objecs changes based on * the state of the connection (resolving, connected or closed) - * a shared pointer is used because we use a forward declaration, which isn't - * allowed in a unique pointer - * @var std::shared_ptr + * @var std::unique_ptr */ std::shared_ptr _state; @@ -116,7 +114,7 @@ public: /** * Destructor */ - virtual ~TcpConnection() noexcept {} + virtual ~TcpConnection() noexcept; /** * The filedescriptor that is used for this connection diff --git a/src/linux_tcp/tcpconnection.cpp b/src/linux_tcp/tcpconnection.cpp index f0663c3..b1141b9 100644 --- a/src/linux_tcp/tcpconnection.cpp +++ b/src/linux_tcp/tcpconnection.cpp @@ -4,7 +4,7 @@ * Implementation file for the TCP connection * * @author Emiel Bruijntjes - * @copyright 2015 - 2016 Copernica BV + * @copyright 2015 - 2018 Copernica BV */ /** @@ -27,6 +27,11 @@ TcpConnection::TcpConnection(TcpHandler *handler, const Address &address) : _state(new TcpResolver(this, address.hostname(), address.port(), address.secure(), handler)), _connection(this, address.login(), address.vhost()) {} +/** + * Destructor + */ +TcpConnection::~TcpConnection() noexcept = default; + /** * The filedescriptor that is used for this connection * @return int