thanks Vinnie and Ivan. So it's either block w/ timeout or use an
asynchronus timeout timer.
Blocking for me is out considering I don't wanted to tie up my event loop.
the non-graceful SSL shutdown... It's really not a problem for the protocol
I'm wrapping.
Post by ivan kostovI have a similar issue with async_write on a closed socket. In this case I
didn't found any way to return with an error. You can setup a c++11 future
and wait_for(timeout) on it.
if( future.wait_for(std::chrono::milliseconds(100))!=
std::future_status::ready )
{
// error handling
}
Post by Vinnie FalcoPost by Adam CrainWhen shutting down a ssl_stream asynchronously, what happens if the
remote side never responds? Does the callback handler never fire?
http://think-async.com/Asio/asio-1.10.6/doc/asio/reference/s
sl__stream/async_shutdown.html
To my knowledge, no asynchronous Asio operations have built-in timeouts.
Its up to callers to set up a timer and cancel the I/O if the timer
expires. When canceling the I/O make sure you do it from the same implicit
or explicit strand that the completion handlers are using.
Disclaimer: I have not looked at the actual implementation for
ssl_stream::async_shutdown.
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
asio-users mailing list
https://lists.sourceforge.net/lists/listinfo/asio-users
_______________________________________________
Using Asio? List your project at
http://think-async.com/Asio/WhoIsUsingAsio
------------------------------------------------------------
------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
asio-users mailing list
https://lists.sourceforge.net/lists/listinfo/asio-users
_______________________________________________
Using Asio? List your project at
http://think-async.com/Asio/WhoIsUsingAsio