io: don't forget to initialise the mmap size for zero length mappings
This commit is contained in:
parent
4a4d5f297a
commit
b87517759d
@ -47,6 +47,7 @@ mapped_file::mapped_file (::cruft::posix::fd const &src, int const mflags)
|
||||
// accepted by some systems; like Linux)
|
||||
if (meta.st_size == 0) {
|
||||
m_data = nullptr;
|
||||
m_size = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user