fix(win): check for error on unmap
@@ -255,11 +255,11 @@ where
warn!("New allocation distance to previous allocation is below threshold.");
// remove previous file mapping
- windows::Win32::System::Memory::UnmapViewOfFile(random_mapping);
-
+ if !windows::Win32::System::Memory::UnmapViewOfFile(random_mapping) {
if let Err(e) = last_error() {
return Err(e);
}
+ }
continue;
}
