NES core - fix loadstate to read until the [NES] tag

This commit is contained in:
andres.delikat 2011-09-04 18:27:53 +00:00
parent 71833f419a
commit eb1aca8695
1 changed files with 9 additions and 1 deletions

View File

@ -694,7 +694,15 @@ namespace BizHawk
sections.Push(name);
if (IsText)
if (IsWriter) { tw.WriteLine("[{0}]", name); }
else { tr.ReadLine(); }
else
{
string str;
while ((str = tr.ReadLine()) != null)
{
if (str.Contains('[' + name + ']'))
return;
}
}
}
public void EndSection()