mirror of
https://github.com/Links2004/arduinoWebSockets.git
synced 2025-07-14 15:56:30 +02:00
Fix socket.io issue
Fix socket.io issue reference from https://github.com/Links2004/arduinoWebSockets/issues/167#issuecomment-276724057
This commit is contained in:
@ -507,8 +507,12 @@ void WebSocketsClient::handleHeader(WSclient_t * client, String * headerLine) {
|
||||
} else if(headerName.equalsIgnoreCase("Sec-WebSocket-Version")) {
|
||||
client->cVersion = headerValue.toInt();
|
||||
} else if(headerName.equalsIgnoreCase("Set-Cookie")) {
|
||||
if (headerValue.indexOf("HttpOnly") > -1) {
|
||||
client->cSessionId = headerValue.substring(headerValue.indexOf('=') + 1, headerValue.indexOf(";"));
|
||||
} else {
|
||||
client->cSessionId = headerValue.substring(headerValue.indexOf('=') + 1);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
DEBUG_WEBSOCKETS("[WS-Client][handleHeader] Header error (%s)\n", headerLine->c_str());
|
||||
}
|
||||
|
Reference in New Issue
Block a user