Fix build warnings (errors on CI) due to mmap flag rename and deprecation.

This commit is contained in:
Chris Fallin
2020-06-03 09:35:09 -07:00
parent a76639c6fb
commit b8e31d7c8e
3 changed files with 7 additions and 7 deletions

View File

@@ -182,7 +182,7 @@ impl Mmap {
// Commit the accessible size.
let ptr = self.ptr as *const u8;
unsafe { region::protect(ptr.add(start), len, region::Protection::ReadWrite) }
unsafe { region::protect(ptr.add(start), len, region::Protection::READ_WRITE) }
.map_err(|e| e.to_string())
}