mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
LibCore: TCP and UDP servers should parent Notifiers to themselves
This makes things look a little more neat in Inspector. :^)
This commit is contained in:
parent
aa149b9330
commit
3713d31750
Notes:
sideshowbarker
2024-07-19 09:28:17 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/3713d317500
2 changed files with 2 additions and 2 deletions
|
@ -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();
|
||||
|
|
|
@ -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();
|
||||
|
|
Loading…
Reference in a new issue