Fix winmm midi driver hanging on content closing

midiStreamStop can freeze the process when there has been a NOTE-ON message without a corresponding NOTE-OFF.
Just removing the call to midiStreamStop and letting the midiStreamClose below it do the entire stopping and closing fixes that.
This commit is contained in:
Bernhard Schelling 2021-01-03 03:22:31 +09:00 committed by GitHub
parent bfaa6e16dd
commit 8a1ca893f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,7 +17,7 @@
#include <libretro.h>
#include <lists/string_list.h>
#include <verbosity.h>
#include "../../verbosity.h"
#include <string/stdstring.h>
#include "../midi_driver.h"
@ -481,7 +481,6 @@ static void winmm_midi_free(void *p)
if (d->out_dev)
{
midiStreamStop(d->out_dev);
winmm_midi_free_output_buffers(d->out_dev, d->out_bufs);
midiStreamClose(d->out_dev);
}