fix possible crash when closing Furnace

This commit is contained in:
tildearrow 2022-08-07 17:37:07 -05:00
parent f80488d9b0
commit b8012344e7

View file

@ -3339,6 +3339,7 @@ bool DivEngine::initAudioBackend() {
bool DivEngine::deinitAudioBackend() {
if (output!=NULL) {
output->quit();
if (output->midiIn) {
if (output->midiIn->isDeviceOpen()) {
logI("closing MIDI input.");
@ -3352,7 +3353,6 @@ bool DivEngine::deinitAudioBackend() {
}
}
output->quitMidi();
output->quit();
delete output;
output=NULL;
//audioEngine=DIV_AUDIO_NULL;