Maximus32
Developer
The problem is somewhere in these functions (or any of the functions they call):
Removing the sfx delay time fixes the issue. Removing audsrv_quit, deinitAllSupport or guiEnd may also solve the issue. Increasing the delay time also increases the chance of failure.
I'm just doing trial and error, but have not found the root-cause yet.
Code:
void sysExecExit(void)
{
if (gEnableSFX) {
//wait 70ms for confirm sound to finish playing before exit
guiDelay(0070);
}
//Deinitialize without shutting down active devices.
deinit(NO_EXCEPTION, IO_MODE_SELECTED_ALL);
Exit(0);
}
...
void deinit(int exception, int modeSelected)
{
// block all io ops, wait for the ones still running to finish
ioBlockOps(1);
guiExecDeferredOps();
if (gEnableSFX) {
gEnableSFX = 0;
}
audsrv_quit();
#ifdef PADEMU
ds34usb_reset();
ds34bt_reset();
#endif
unloadPads();
deinitAllSupport(exception, modeSelected);
ioEnd();
guiEnd();
menuEnd();
lngEnd();
thmEnd();
rmEnd();
configEnd();
}
I'm just doing trial and error, but have not found the root-cause yet.