From 7a56113d69c5a56ea333f87c5d67cd5a371aa090 Mon Sep 17 00:00:00 2001 From: littleblack111 Date: Fri, 7 Mar 2025 18:02:11 +0800 Subject: fix: session not disconnected properly perf: use server sockfd directly instead of a dupe of it --- src/session.hpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/session.hpp') diff --git a/src/session.hpp b/src/session.hpp index 0c5e4f9..d5fb7e6 100644 --- a/src/session.hpp +++ b/src/session.hpp @@ -2,7 +2,9 @@ #include "FileDescriptor.hpp" #include "format.hpp" +#include #include +#include class CSession { public: @@ -21,8 +23,10 @@ class CSession { template bool write(eFormatType type, std::format_string fmt, Args &&...args) const; void run(); + void setSelf(std::pair> *self); private: + std::pair> *self; enum eEventType { READ, WRITE -- cgit v1.2.3