aboutsummaryrefslogtreecommitdiffstats
path: root/modules/websocket.cpp
diff options
context:
space:
mode:
authorGravatar Sadie Powell2025-10-26 16:46:19 +0000
committerGravatar Sadie Powell2025-10-26 16:46:19 +0000
commit9beffb09a77202cc344f7037097b3ce7b8fadb62 (patch)
treec77bd1a4141a52066c3f0f964ed470621041bd64 /modules/websocket.cpp
parentMerge branch 'insp4' into master. (diff)
downloadinspircd++-9beffb09a77202cc344f7037097b3ce7b8fadb62.tar.gz
inspircd++-9beffb09a77202cc344f7037097b3ce7b8fadb62.tar.bz2
inspircd++-9beffb09a77202cc344f7037097b3ce7b8fadb62.zip
Start splitting the user I/O interface from the network socket.
Diffstat (limited to 'modules/websocket.cpp')
-rw-r--r--modules/websocket.cpp8
1 files changed, 4 insertions, 4 deletions
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<UserIOHandler*>(sock);
- ioh->user->lastping = 1;
+ auto* lio = reinterpret_cast<LocalUserIO*>(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<UserIOHandler*>(sock)->user;
+ luser = reinterpret_cast<LocalUserIO*>(sock)->user;
bool allowedorigin = false;
HTTPHeaderFinder originheader;
@@ -754,7 +754,7 @@ public:
return;
LocalUser* user = IS_LOCAL(static_cast<User*>(item));
- if ((user) && (user->eh.GetModHook(this)))
+ if ((user) && (user->io->GetSocket()->GetModHook(this)))
ServerInstance->Users.QuitUser(user, "WebSocket module unloading");
}