mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 14:27:35 +00:00
AK: Add method to create MappedFile from fd
This commit is contained in:
parent
95ee7069d5
commit
bc75ca4fe5
2 changed files with 10 additions and 0 deletions
|
@ -20,6 +20,7 @@ class MappedFile : public RefCounted<MappedFile> {
|
|||
|
||||
public:
|
||||
static Result<NonnullRefPtr<MappedFile>, OSError> map(const String& path);
|
||||
static Result<NonnullRefPtr<MappedFile>, OSError> map_from_fd_and_close(int fd, String const& path);
|
||||
~MappedFile();
|
||||
|
||||
void* data() { return m_data; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue