diff options
author | Devaev Maxim <[email protected]> | 2021-05-26 12:26:31 +0300 |
---|---|---|
committer | Devaev Maxim <[email protected]> | 2021-05-26 12:26:31 +0300 |
commit | e4806297242c69fab8967b7e1d2d1a81dd17d744 (patch) | |
tree | ae61f672848a5e3289c6d75371b71c01e2bc1722 /kvmd/plugins/msd/relay/drive.py | |
parent | 5da412ae7cad952c58e5190aaabed39afd3cdb66 (diff) |
speed up msd
Diffstat (limited to 'kvmd/plugins/msd/relay/drive.py')
-rw-r--r-- | kvmd/plugins/msd/relay/drive.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/kvmd/plugins/msd/relay/drive.py b/kvmd/plugins/msd/relay/drive.py index 1f6c7c08..e9b9f681 100644 --- a/kvmd/plugins/msd/relay/drive.py +++ b/kvmd/plugins/msd/relay/drive.py @@ -129,7 +129,8 @@ class DeviceInfo: if self.size - image_info.size > _IMAGE_INFO_SIZE: await device_file.seek(self.size - _IMAGE_INFO_SIZE) # type: ignore - await aiofs.afile_write_now(device_file, image_info.to_bytes()) + await device_file.write(image_info.to_bytes()) # type: ignore + await aiofs.afile_sync(device_file) await device_file.seek(0) # type: ignore return True return False # Device is full |