1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-30 21:48:11 +00:00

Kernel: Call did_modify_contents() after truncate()

Truncating a file should absolutly mark it as modified. With this
change our `tail` implementation can correctly handle it.
This commit is contained in:
Fabian Dellwing 2024-02-12 20:25:34 +01:00 committed by Andrew Kaster
parent 525555181e
commit 5180e41918
3 changed files with 3 additions and 0 deletions

View file

@ -1078,6 +1078,7 @@ ErrorOr<void> Ext2FSInode::truncate(u64 size)
return {};
TRY(resize(size));
set_metadata_dirty(true);
did_modify_contents();
return {};
}