From 3713d317500e8595c7940dcef3e1e31513ed4456 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Mon, 10 Feb 2020 14:15:56 +0100 Subject: [PATCH] LibCore: TCP and UDP servers should parent Notifiers to themselves This makes things look a little more neat in Inspector. :^) --- Libraries/LibCore/TCPServer.cpp | 2 +- Libraries/LibCore/UdpServer.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Libraries/LibCore/TCPServer.cpp b/Libraries/LibCore/TCPServer.cpp index 9a730325f49..bfc8a9ce61f 100644 --- a/Libraries/LibCore/TCPServer.cpp +++ b/Libraries/LibCore/TCPServer.cpp @@ -60,7 +60,7 @@ bool TCPServer::listen(const IPv4Address& address, u16 port) ASSERT(rc == 0); m_listening = true; - m_notifier = Notifier::construct(m_fd, Notifier::Event::Read); + m_notifier = Notifier::construct(m_fd, Notifier::Event::Read, this); m_notifier->on_ready_to_read = [this] { if (on_ready_to_accept) on_ready_to_accept(); diff --git a/Libraries/LibCore/UdpServer.cpp b/Libraries/LibCore/UdpServer.cpp index 6145115af85..a1b9bd8a8d1 100644 --- a/Libraries/LibCore/UdpServer.cpp +++ b/Libraries/LibCore/UdpServer.cpp @@ -60,7 +60,7 @@ bool UdpServer::listen(const IPv4Address& address, u16 port) ASSERT(rc == 0); m_listening = true; - m_notifier = Notifier::construct(m_fd, Notifier::Event::Read); + m_notifier = Notifier::construct(m_fd, Notifier::Event::Read, this); m_notifier->on_ready_to_read = [this] { if (on_ready_to_accept) on_ready_to_accept();