diff options
author | Andreas Kling <kling@serenityos.org> | 2021-04-23 16:46:57 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-04-23 16:46:57 +0200 |
commit | b91c49364df1683c7fe1191eb02b8d9c331874f6 (patch) | |
tree | a9ea5ff8e4cc8cfcfe75c279551be35793d0ffb3 /Kernel/VM/PageDirectory.h | |
parent | b3db01e20eeae632cc75df9af8666772bda67091 (diff) | |
download | serenity-b91c49364df1683c7fe1191eb02b8d9c331874f6.zip |
AK: Rename adopt() to adopt_ref()
This makes it more symmetrical with adopt_own() (which is used to
create a NonnullOwnPtr from the result of a naked new.)
Diffstat (limited to 'Kernel/VM/PageDirectory.h')
-rw-r--r-- | Kernel/VM/PageDirectory.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Kernel/VM/PageDirectory.h b/Kernel/VM/PageDirectory.h index d965d883ec..6f1a5bfbe5 100644 --- a/Kernel/VM/PageDirectory.h +++ b/Kernel/VM/PageDirectory.h @@ -22,12 +22,12 @@ class PageDirectory : public RefCounted<PageDirectory> { public: static RefPtr<PageDirectory> create_for_userspace(const RangeAllocator* parent_range_allocator = nullptr) { - auto page_directory = adopt(*new PageDirectory(parent_range_allocator)); + auto page_directory = adopt_ref(*new PageDirectory(parent_range_allocator)); if (!page_directory->is_valid()) return {}; return page_directory; } - static NonnullRefPtr<PageDirectory> create_kernel_page_directory() { return adopt(*new PageDirectory); } + static NonnullRefPtr<PageDirectory> create_kernel_page_directory() { return adopt_ref(*new PageDirectory); } static RefPtr<PageDirectory> find_by_cr3(u32); ~PageDirectory(); |