http_timeout must be 0 when upgrading to websockets

otherwise kore will timeout an established websocket connection
after http_timeout seconds.
This commit is contained in:
Joris Vink 2019-05-05 14:47:04 +02:00
parent fe84997ce9
commit 503f42074c
1 changed files with 1 additions and 0 deletions

View File

@ -105,6 +105,7 @@ kore_websocket_handshake(struct http_request *req, const char *onconnect,
req->owner->disconnect = websocket_disconnect;
req->owner->rnb->flags &= ~NETBUF_CALL_CB_ALWAYS;
req->owner->http_timeout = 0;
req->owner->idle_timer.start = kore_time_ms();
req->owner->idle_timer.length = kore_websocket_timeout;