cpprestsdk
cpprestsdk copied to clipboard
Websocket Connect/Disconnect crash or block forever
i am working on the websocket disconnect checking, and i found that when i turn off the network, those msg suppose will not send(since the network are disconnected) will block for a while and resend after connect again(also the period it block after reconnect depend on how long you disconnect), that is not i want
so i try to disconnect manually(websocket_callback_client.close().wait()) when i detected disconnect to avoid msg resend again, but it is not working too, the disconnect function will blocking forever, also i try to connect again manually(client.connect(U(websocket_url)).wait();), it will crash(Assertion `m_state == CREATED' failed)
what should i do to check the connection? and avoid the msg resend again?
any one can help?
I have the same problem at the moment and was wondering if somebody has the answer!
When I try to reconnect after the websocket lost connection, it will give the same error as q18roychoi stated.
same problem
me too, same problem。anyone can double checking this issues?