saturn - fix crash in dead or alive

It does look pretty awful with interlacing, but that's not something bizhawk is equipped to solve at present
This commit is contained in:
nattthebear 2020-06-14 10:15:05 -04:00
parent 3610ca2b4c
commit 7ba3f6db03
3 changed files with 9 additions and 5 deletions
output/dll
src/BizHawk.Emulation.Cores/Waterbox
waterbox/nyma

Binary file not shown.

View File

@ -142,7 +142,7 @@ namespace BizHawk.Emulation.Cores.Waterbox
private void PrintGdbData()
{
Console.WriteLine("GDB Symbol Load:");
Console.WriteLine($" add-sym {ModuleName}");
Console.WriteLine($" add-sym {ModuleName} -s .text {_elf.Sections.Single(s => s.Name == ".text").LoadAddress}");
}
private void PrintSections()

View File

@ -184,9 +184,13 @@ ECL_EXPORT void FrameAdvance(MyFrameInfo& frame)
for (int line = lineStart; line < lineEnd; line++)
{
memcpy(dst, src, (multiWidth ? EES->LineWidths[line] : w) * sizeof(uint32_t));
src += srcp;
dst += dstp;
auto lw = multiWidth ? EES->LineWidths[line] : w;
if (MDFN_LIKELY(lw > 0))
{
memcpy(dst, src, lw * sizeof(uint32_t));
src += srcp;
dst += dstp;
}
}
}
else
@ -207,7 +211,7 @@ ECL_EXPORT void FrameAdvance(MyFrameInfo& frame)
memcpy(dst, src, w * sizeof(uint32_t));
dst += dstp;
}
else
else if (MDFN_LIKELY(w > 0))
{
// stretch horizontal
int wf = Game->lcm_width / w;