From 94fe989840263bb4adbee16635a14dcd007adc53 Mon Sep 17 00:00:00 2001 From: Peter Thorson Date: Wed, 6 Apr 2016 09:38:45 -0400 Subject: [PATCH] Store loggers in shared pointers references #501 #537 adds related changelog entry and fix one overzealous find and replace operation. --- changelog.md | 4 ++++ websocketpp/transport/asio/connection.hpp | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/changelog.md b/changelog.md index 0640470..915efcf 100644 --- a/changelog.md +++ b/changelog.md @@ -6,6 +6,10 @@ HEAD - Compatibility: Make sure the chrono library used by Boost/Asio is in sync with what the websocketpp is using. Thank you Flow86 for reporting and a patch. +- Bug: Store loggers in shared pointers to avoid crashes related to connections + trying to write logs entries after their respective endpoint has been + deallocated. Thank you Thalhammer for reporting and Jupp Müller for the + patch. #539 #501 0.7.0 - 2016-02-22 - MINOR BREAKING SOCKET POLICY CHANGE: Asio transport socket policy method diff --git a/websocketpp/transport/asio/connection.hpp b/websocketpp/transport/asio/connection.hpp index 518aa92..5428c5f 100644 --- a/websocketpp/transport/asio/connection.hpp +++ b/websocketpp/transport/asio/connection.hpp @@ -1120,7 +1120,7 @@ protected: // TLS short read at this point is somewhat expected if both // sides try and end the connection at the same time or if // SSLv2 is being used. In general there is nothing that can - // be done here other than a low level development log-> + // be done here other than a low level development log. } else { // all other errors are effectively pass through errors of // some sort so print some detail on the info channel for