WindowServer: Fix fd closing

Don't close fds in Window destructor :P
This commit is contained in:
2026-07-04 07:33:41 +03:00
parent c9b3d50523
commit b2169cbce6
2 changed files with 1 additions and 2 deletions

View File

@@ -31,8 +31,6 @@ Window::~Window()
total_sent += nsend; total_sent += nsend;
} }
} }
close(m_client_fd);
} }
BAN::ErrorOr<void> Window::initialize(BAN::StringView title, uint32_t width, uint32_t height) BAN::ErrorOr<void> Window::initialize(BAN::StringView title, uint32_t width, uint32_t height)

View File

@@ -326,6 +326,7 @@ int main()
if (auto ret = window_server.add_client_fd(client_fd); ret.is_error()) if (auto ret = window_server.add_client_fd(client_fd); ret.is_error())
{ {
dwarnln("add_client: {}", ret.error()); dwarnln("add_client: {}", ret.error());
epoll_ctl(g_epoll_fd, EPOLL_CTL_DEL, client_fd, nullptr);
close(client_fd); close(client_fd);
continue; continue;
} }