From 1ec96bc2063579f8e2f73944974cadcb15e348b0 Mon Sep 17 00:00:00 2001 From: Jordan Schidlowsky Date: Sat, 29 Jan 2022 00:29:27 +0100 Subject: [Net] Non-blocking WebSocket hostname resolution. Hostname is now resolved during poll in WebSocketClient (wslay) to avoid blocking during connect. An attempt is still made to find the hostname in the resolver cache. --- modules/websocket/wsl_client.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'modules/websocket/wsl_client.h') diff --git a/modules/websocket/wsl_client.h b/modules/websocket/wsl_client.h index 4839d7ab9b..d846e6be00 100644 --- a/modules/websocket/wsl_client.h +++ b/modules/websocket/wsl_client.h @@ -63,10 +63,11 @@ private: String _key; String _host; - int _port; - Array ip_candidates; + uint16_t _port; + Array _ip_candidates; Vector _protocols; bool _use_ssl = false; + IP::ResolverID _resolver_id = IP::RESOLVER_INVALID_ID; void _do_handshake(); bool _verify_headers(String &r_protocol); -- cgit v1.2.3