mirror of https://github.com/SourMesen/Mesen2
Movies: Fixed last emulation setting stored in movie file not being applied correctly
This commit is contained in:
parent
0f08c71c5a
commit
f2e071d435
|
|
@ -178,7 +178,7 @@ bool Serializer::LoadFromTextFormat(istream& file)
|
|||
}
|
||||
|
||||
i += (uint32_t)key.size() + 1;
|
||||
if(i >= size - 4) {
|
||||
if(i >= size) {
|
||||
//invalid
|
||||
return false;
|
||||
}
|
||||
|
|
@ -191,7 +191,7 @@ bool Serializer::LoadFromTextFormat(istream& file)
|
|||
}
|
||||
}
|
||||
|
||||
if(i + valueSize > size) {
|
||||
if(i + valueSize > size || valueSize == 0) {
|
||||
//invalid
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue