diff options
author | Idan Horowitz <idan.horowitz@gmail.com> | 2022-02-10 19:59:26 +0200 |
---|---|---|
committer | Idan Horowitz <idan.horowitz@gmail.com> | 2022-02-11 17:49:46 +0200 |
commit | 75fe51a9ca4d79d46532a38f62fc04d6e1cd673b (patch) | |
tree | 0ea55b7bfde775b189be121949f3ee2184faea4b /Kernel/Memory | |
parent | 57bce8ab97f52c01698fe6ce9e2289be704f3cc5 (diff) | |
download | serenity-75fe51a9ca4d79d46532a38f62fc04d6e1cd673b.zip |
Kernel: Stop trying to write unmapped Process regions into CoreDumps
If we crashed in the middle of mapping in Regions, some of the regions
may not have a page directory yet, and will result in a crash when
Region::remap() is called.
Diffstat (limited to 'Kernel/Memory')
-rw-r--r-- | Kernel/Memory/Region.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Kernel/Memory/Region.h b/Kernel/Memory/Region.h index 54380fe7ed..dcaeae18a0 100644 --- a/Kernel/Memory/Region.h +++ b/Kernel/Memory/Region.h @@ -188,6 +188,8 @@ public: void remap(); + [[nodiscard]] bool is_mapped() const { return m_page_directory != nullptr; } + void clear_to_zero(); [[nodiscard]] bool is_syscall_region() const { return m_syscall_region; } |