diff --git a/src/util/memorymappedfile.cpp b/src/util/memorymappedfile.cpp index 194fc4fe..c2aaf837 100644 --- a/src/util/memorymappedfile.cpp +++ b/src/util/memorymappedfile.cpp @@ -152,6 +152,11 @@ bool MemoryMappedFile::MapFile(const wxString& filePath, m_open = true; return true; } + else if (m_mapSize == 0) + { + Reset(); + throw MemoryMappedFileEmptyException(); + } else { Reset();