mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:07:44 +00:00
Kernel: Set the dumpable flag before switching spaces in sys$execve()
This commit is contained in:
parent
d746639171
commit
45231051e6
1 changed files with 2 additions and 2 deletions
|
@ -501,6 +501,8 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
|
|||
}
|
||||
}
|
||||
|
||||
set_dumpable(!executable_is_setid);
|
||||
|
||||
m_space = load_result.space.release_nonnull();
|
||||
MemoryManager::enter_space(*m_space);
|
||||
|
||||
|
@ -525,8 +527,6 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
|
|||
|
||||
clear_futex_queues_on_exec();
|
||||
|
||||
set_dumpable(!executable_is_setid);
|
||||
|
||||
for (size_t i = 0; i < m_fds.size(); ++i) {
|
||||
auto& description_and_flags = m_fds[i];
|
||||
if (description_and_flags.description() && description_and_flags.flags() & FD_CLOEXEC)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue