diff options
author | Tom <tomut@yahoo.com> | 2020-09-27 08:53:35 -0600 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-09-27 19:46:04 +0200 |
commit | 838d9fa251ed34289cb9c77eb46f889dc9e79416 (patch) | |
tree | 0efecf56806d2fff7ebfbe5b28288a8ac01c5600 /Kernel/Net/NetworkTask.cpp | |
parent | 079486ed7eba3d15567bb5ee9677c81dd190cffa (diff) | |
download | serenity-838d9fa251ed34289cb9c77eb46f889dc9e79416.zip |
Kernel: Make Thread refcounted
Similar to Process, we need to make Thread refcounted. This will solve
problems that will appear once we schedule threads on more than one
processor. This allows us to hold onto threads without necessarily
holding the scheduler lock for the entire duration.
Diffstat (limited to 'Kernel/Net/NetworkTask.cpp')
-rw-r--r-- | Kernel/Net/NetworkTask.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Net/NetworkTask.cpp b/Kernel/Net/NetworkTask.cpp index ff2816ea12..913ad877c2 100644 --- a/Kernel/Net/NetworkTask.cpp +++ b/Kernel/Net/NetworkTask.cpp @@ -61,7 +61,7 @@ static void handle_tcp(const IPv4Packet&, const timeval& packet_timestamp); void NetworkTask::spawn() { - Thread* thread = nullptr; + RefPtr<Thread> thread; Process::create_kernel_process(thread, "NetworkTask", NetworkTask_main); } |