mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 11:38:11 +00:00
Kernel: Make Kernel::VMObject allocation functions return KResultOr
This makes for nicer handling of errors compared to checking whether a RefPtr is null. Additionally, this will give way to return different types of errors in the future.
This commit is contained in:
parent
61c0e3ca92
commit
4bfd6e41b9
26 changed files with 194 additions and 122 deletions
|
@ -19,7 +19,7 @@ public:
|
|||
virtual ~PrivateInodeVMObject() override;
|
||||
|
||||
static RefPtr<PrivateInodeVMObject> try_create_with_inode(Inode&);
|
||||
virtual RefPtr<VMObject> try_clone() override;
|
||||
virtual KResultOr<NonnullRefPtr<VMObject>> try_clone() override;
|
||||
|
||||
private:
|
||||
virtual bool is_private_inode() const override { return true; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue