Software: Fix crash on startup when using "Compile Shaders Before Starting"

When that setting is enabled, m_xfb_entry is initially not present (during the phase where a shader compilation progress bar would be shown). The main path checks for m_xfb_entry, but the software renderer fallback path didn't.

Fixes another aspect of https://bugs.dolphin-emu.org/issues/13172.
This commit is contained in:
Pokechu22 2023-02-18 12:28:15 -08:00
parent 4a2d3c83c7
commit 78428dd8db
1 changed files with 4 additions and 3 deletions

View File

@ -521,9 +521,10 @@ void Presenter::Present()
if (!g_gfx->SupportsUtilityDrawing())
{
// Video Software doesn't support Drawing a UI or doing post-processing
// So just Show the XFB
g_gfx->ShowImage(m_xfb_entry->texture.get(), m_xfb_rect);
// Video Software doesn't support drawing a UI or doing post-processing
// So just show the XFB
if (m_xfb_entry)
g_gfx->ShowImage(m_xfb_entry->texture.get(), m_xfb_rect);
return;
}