MCPcopy Create free account
hub / github.com/JoaoLopesF/RemoteDebug / remoteIP

Method remoteIP

src/utility/WebSocketsServer.cpp:430–439  ·  view source on GitHub ↗

* get an IP for a client * @param num uint8_t client id * @return IPAddress */

Source from the content-addressed store, hash-verified

428 * @return IPAddress
429 */
430IPAddress WebSocketsServer::remoteIP(uint8_t num) {
431 if(num < WEBSOCKETS_SERVER_CLIENT_MAX) {
432 WSclient_t * client = &_clients[num];
433 if(clientIsConnected(client)) {
434 return client->tcp->remoteIP();
435 }
436 }
437
438 return IPAddress();
439}
440#endif
441
442//#################################################################################

Callers 4

handleMethod · 0.80
webSocketEventFunction · 0.80
newClientMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected