Make strand destruction a no-op, to allow strand objects to be destroyed after their associated io_service has been destroyed.
diff --git a/asio/include/asio/detail/impl/strand_service.hpp b/asio/include/asio/detail/impl/strand_service.hpp index 85485f0..3b7ee23 100644 --- a/asio/include/asio/detail/impl/strand_service.hpp +++ b/asio/include/asio/detail/impl/strand_service.hpp
@@ -49,11 +49,6 @@ } }; -inline void strand_service::destroy(strand_service::implementation_type& impl) -{ - impl = 0; -} - template <typename Handler> void strand_service::dispatch(strand_service::implementation_type& impl, Handler handler)
diff --git a/asio/include/asio/detail/strand_service.hpp b/asio/include/asio/detail/strand_service.hpp index d2fd6e6..53b334c 100644 --- a/asio/include/asio/detail/strand_service.hpp +++ b/asio/include/asio/detail/strand_service.hpp
@@ -83,9 +83,6 @@ // Construct a new strand implementation. ASIO_DECL void construct(implementation_type& impl); - // Destroy a strand implementation. - void destroy(implementation_type& impl); - // Request the io_service to invoke the given handler. template <typename Handler> void dispatch(implementation_type& impl, Handler handler);
diff --git a/asio/include/asio/strand.hpp b/asio/include/asio/strand.hpp index 92f6ccc..8324b14 100644 --- a/asio/include/asio/strand.hpp +++ b/asio/include/asio/strand.hpp
@@ -104,7 +104,6 @@ */ ~strand() { - service_.destroy(impl_); } /// Get the io_service associated with the strand.