mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 01:47:35 +00:00
LibCore: Add Core::IODevice::truncate()
This is just a wrapper around ftruncate(). Today I also learned that ftruncate() does not reset the file descriptor offset. :^)
This commit is contained in:
parent
9dafbc82ff
commit
35b844ba4c
2 changed files with 12 additions and 0 deletions
|
@ -65,6 +65,8 @@ public:
|
|||
bool write(const u8*, int size);
|
||||
bool write(const StringView&);
|
||||
|
||||
bool truncate(off_t);
|
||||
|
||||
bool can_read_line() const;
|
||||
|
||||
bool can_read() const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue