Fix a nullptr dereference in EmuDirectSoundBuffer8_Stop
Eggo Mania no longer crashes, but instad shows a 'disc is dirty or damaged' screen
This commit is contained in:
parent
90d2a34090
commit
1f5f4f3ad0
|
@ -1444,10 +1444,12 @@ HRESULT WINAPI XTL::EmuIDirectSoundBuffer8_Stop
|
|||
");\n",
|
||||
GetCurrentThreadId(), pThis);
|
||||
|
||||
HRESULT hRet = pThis->EmuDirectSoundBuffer8->Stop();
|
||||
|
||||
HRESULT hRet = D3D_OK;
|
||||
|
||||
|
||||
if (pThis != nullptr) {
|
||||
hRet = pThis->EmuDirectSoundBuffer8->Stop();
|
||||
}
|
||||
|
||||
return hRet;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue