1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 06:48:12 +00:00

Kernel: Drop futex queues/state on exec()

This state is not meaningful to the new process image so just drop it.
This commit is contained in:
Andreas Kling 2020-01-17 16:07:20 +01:00
parent 26a31c7efb
commit 4d4d5e1c07

View file

@ -820,6 +820,8 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
current->m_signal_mask = 0;
current->m_pending_signals = 0;
m_futex_queues.clear();
for (int i = 0; i < m_fds.size(); ++i) {
auto& daf = m_fds[i];
if (daf.description && daf.flags & FD_CLOEXEC) {