Kernel: Allow Ext2FS::flush_writes() to return ErrorOr<void>

This commit is contained in:
Zak-K-Abdi 2023-08-01 07:48:43 +01:00 committed by Sam Atkins
commit abcf05801a
Notes: sideshowbarker 2024-07-17 20:33:50 +09:00
8 changed files with 26 additions and 12 deletions

View file

@ -48,7 +48,11 @@ void Inode::sync()
{
if (is_metadata_dirty())
(void)flush_metadata();
fs().flush_writes();
auto result = fs().flush_writes();
if (result.is_error()) {
// TODO: Figure out how to propagate error to a higher function.
}
}
ErrorOr<NonnullRefPtr<Custody>> Inode::resolve_as_link(Credentials const& credentials, Custody& base, RefPtr<Custody>* out_parent, int options, int symlink_recursion_level) const