[ad_1]
I use boost asio for sync socket server and client.
using socket_base::bytes_readable to get whether there is any data to read, as suggested here
worked great for me.
Now I’ve converted the code to support ssl (using asio::ssl::stream), and the first client read after a the handshake detects 478 bytes to read (should be none) and gets stuck on WSARecv during the read attempt (since there is nothing to read).
Switching to async is not an option right now.
Anyone had experience with this problem or any tips how to resolve it?
[ad_2]