diff --git a/repos/ports/src/noux/vfs_io_channel.h b/repos/ports/src/noux/vfs_io_channel.h index 3c57774f3a..7f8bad759e 100644 --- a/repos/ports/src/noux/vfs_io_channel.h +++ b/repos/ports/src/noux/vfs_io_channel.h @@ -88,12 +88,14 @@ struct Noux::Vfs_io_channel : Io_channel Registered_no_delete vfs_io_waiter(_vfs_io_waiter_registry); - for (;;) { - if (_fh.fs().update_modification_timestamp(&_fh, ts)) { - break; - } else { - Genode::error("_sync: update_modification_timestamp failed"); - vfs_io_waiter.wait_for_io(); + if (_fh.status_flags() != Sysio::OPEN_MODE_RDONLY) { + for (;;) { + if (_fh.fs().update_modification_timestamp(&_fh, ts)) { + break; + } else { + Genode::error("_sync: update_modification_timestamp failed"); + vfs_io_waiter.wait_for_io(); + } } }