From 9beffb09a77202cc344f7037097b3ce7b8fadb62 Mon Sep 17 00:00:00 2001 From: Sadie Powell Date: Sun, 26 Oct 2025 16:46:19 +0000 Subject: Start splitting the user I/O interface from the network socket. --- modules/websocket.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'modules/websocket.cpp') diff --git a/modules/websocket.cpp b/modules/websocket.cpp index fdf91fbe0..2538b0451 100644 --- a/modules/websocket.cpp +++ b/modules/websocket.cpp @@ -333,8 +333,8 @@ class WebSocketHook final else if (sock->type == StreamSocket::SS_USER && config.nativeping) { // Pong reply on user socket; reset their idle time. - UserIOHandler* ioh = static_cast(sock); - ioh->user->lastping = 1; + auto* lio = reinterpret_cast(sock); + lio->user->lastping = 1; } return 1; } @@ -427,7 +427,7 @@ class WebSocketHook final LocalUser* luser = nullptr; if (sock->type == StreamSocket::SS_USER) - luser = static_cast(sock)->user; + luser = reinterpret_cast(sock)->user; bool allowedorigin = false; HTTPHeaderFinder originheader; @@ -754,7 +754,7 @@ public: return; LocalUser* user = IS_LOCAL(static_cast(item)); - if ((user) && (user->eh.GetModHook(this))) + if ((user) && (user->io->GetSocket()->GetModHook(this))) ServerInstance->Users.QuitUser(user, "WebSocket module unloading"); } -- cgit v1.3.1-10-gc9f91