RFC requires a port for Host when it is non default. https://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.23

This commit is contained in:
Wayne May
2016-04-30 15:46:19 -07:00
parent b3efb316ed
commit 4f55c36c80

View File

@ -392,7 +392,7 @@ void WebSocketsClient::sendHeader(WSclient_t * client) {
#endif
String handshake = "GET " + client->cUrl + " HTTP/1.1\r\n"
"Host: " + _host + "\r\n"
"Host: " + _host + ":" + _port + "\r\n"
"Upgrade: websocket\r\n"
"Connection: Upgrade\r\n"
"User-Agent: arduino-WebSocket-Client\r\n"
@ -620,6 +620,3 @@ void WebSocketsClient::asyncConnect() {
}
#endif