From d5f3972012c18e7bbf7343e3c4787f8adf51c637 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 27 Sep 2019 19:10:52 +0200 Subject: Kernel: No need to manually deallocate kernel stack Region in ~Thread() Since we're keeping this Region in an OwnPtr, it will be torn down when we get to ~OwnPtr anyway. --- Kernel/Thread.cpp | 3 --- 1 file changed, 3 deletions(-) diff --git a/Kernel/Thread.cpp b/Kernel/Thread.cpp index 1a18f42f3e..9ced4e1806 100644 --- a/Kernel/Thread.cpp +++ b/Kernel/Thread.cpp @@ -121,9 +121,6 @@ Thread::~Thread() if (m_userspace_stack_region) m_process.deallocate_region(*m_userspace_stack_region); - - if (m_kernel_stack_region) - m_process.deallocate_region(*m_kernel_stack_region); } void Thread::unblock() -- cgit v1.2.3