mirror of
https://github.com/Links2004/arduinoWebSockets.git
synced 2025-07-16 08:42:06 +02:00
fix code style
This commit is contained in:
@ -25,7 +25,6 @@
|
|||||||
#include "WebSockets.h"
|
#include "WebSockets.h"
|
||||||
#include "WebSocketsClient.h"
|
#include "WebSocketsClient.h"
|
||||||
|
|
||||||
|
|
||||||
WebSocketsClient::WebSocketsClient() {
|
WebSocketsClient::WebSocketsClient() {
|
||||||
_cbEvent = NULL;
|
_cbEvent = NULL;
|
||||||
_client.num = 0;
|
_client.num = 0;
|
||||||
@ -252,7 +251,6 @@ bool WebSocketsClient::sendPing(String & payload) {
|
|||||||
return sendPing((uint8_t *) payload.c_str(), payload.length());
|
return sendPing((uint8_t *) payload.c_str(), payload.length());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* disconnect one client
|
* disconnect one client
|
||||||
* @param num uint8_t client id
|
* @param num uint8_t client id
|
||||||
@ -297,7 +295,6 @@ void WebSocketsClient::setExtraHeaders(const char * extraHeaders) {
|
|||||||
_client.extraHeaders = extraHeaders;
|
_client.extraHeaders = extraHeaders;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* set the reconnect Interval
|
* set the reconnect Interval
|
||||||
* how long to wait after a connection initiate failed
|
* how long to wait after a connection initiate failed
|
||||||
@ -429,8 +426,7 @@ void WebSocketsClient::handleClientData(void) {
|
|||||||
int len = _client.tcp->available();
|
int len = _client.tcp->available();
|
||||||
if(len > 0) {
|
if(len > 0) {
|
||||||
switch(_client.status) {
|
switch(_client.status) {
|
||||||
case WSC_HEADER:
|
case WSC_HEADER: {
|
||||||
{
|
|
||||||
String headerLine = _client.tcp->readStringUntil('\n');
|
String headerLine = _client.tcp->readStringUntil('\n');
|
||||||
handleHeader(&_client, &headerLine);
|
handleHeader(&_client, &headerLine);
|
||||||
}
|
}
|
||||||
@ -449,7 +445,6 @@ void WebSocketsClient::handleClientData(void) {
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* send the WebSocket header to Server
|
* send the WebSocket header to Server
|
||||||
* @param client WSclient_t * ptr to the client struct
|
* @param client WSclient_t * ptr to the client struct
|
||||||
@ -711,7 +706,6 @@ void WebSocketsClient::connectedCb() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void WebSocketsClient::connectFailedCb() {
|
void WebSocketsClient::connectFailedCb() {
|
||||||
DEBUG_WEBSOCKETS("[WS-Client] connection to %s:%u Faild\n", _host.c_str(), _port);
|
DEBUG_WEBSOCKETS("[WS-Client] connection to %s:%u Faild\n", _host.c_str(), _port);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user