mirror of
https://github.com/warmcat/libwebsockets.git
synced 2025-03-09 00:00:04 +01:00
mqtt: avoid LRS_H1C_ISSUE_HANDSHAKE
Otherwise we can get the client connection stalling since H1C has no meaning on mqtt.
This commit is contained in:
parent
8221450b20
commit
da38af3b2d
1 changed files with 7 additions and 8 deletions
|
@ -196,6 +196,13 @@ send_hs:
|
|||
|
||||
/* we are making our own connection */
|
||||
|
||||
if (!rawish)
|
||||
lwsi_set_state(wsi, LRS_H1C_ISSUE_HANDSHAKE);
|
||||
else {
|
||||
/* for a method = "RAW" connection, this makes us
|
||||
* established */
|
||||
|
||||
|
||||
#if defined(LWS_WITH_TLS) && !defined(LWS_WITH_MBEDTLS)
|
||||
|
||||
/* we have connected if we got here */
|
||||
|
@ -226,18 +233,10 @@ send_hs:
|
|||
lws_set_timeout(wsi, PENDING_TIMEOUT_AWAITING_CLIENT_HS_SEND,
|
||||
wsi->context->timeout_secs);
|
||||
|
||||
//if ()
|
||||
return wsi;
|
||||
}
|
||||
#endif
|
||||
|
||||
if (!rawish)
|
||||
lwsi_set_state(wsi, LRS_H1C_ISSUE_HANDSHAKE);
|
||||
else {
|
||||
/* for a method = "RAW" connection, this makes us
|
||||
* established */
|
||||
|
||||
|
||||
/* clear his established timeout */
|
||||
lws_set_timeout(wsi, NO_PENDING_TIMEOUT, 0);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue