mirror of
https://github.com/ZDoom/fluidsynth.git
synced 2025-01-31 21:50:37 +00:00
Unprepare MIDI buffers
This was missing.
This commit is contained in:
parent
c57d7fffe8
commit
9aeac6ca6e
1 changed files with 13 additions and 0 deletions
|
@ -371,6 +371,8 @@ error_recovery:
|
|||
void
|
||||
delete_fluid_winmidi_driver(fluid_midi_driver_t *p)
|
||||
{
|
||||
int i;
|
||||
|
||||
fluid_winmidi_driver_t *dev = (fluid_winmidi_driver_t *) p;
|
||||
fluid_return_if_fail(dev != NULL);
|
||||
|
||||
|
@ -387,6 +389,17 @@ delete_fluid_winmidi_driver(fluid_midi_driver_t *p)
|
|||
{
|
||||
midiInStop(dev->hmidiin);
|
||||
midiInReset(dev->hmidiin);
|
||||
|
||||
for(i = 0; i < MIDI_SYSEX_BUF_COUNT; i++)
|
||||
{
|
||||
MIDIHDR *hdr = &dev->sysExHdrs[i];
|
||||
|
||||
if ((hdr->dwFlags & MHDR_PREPARED))
|
||||
{
|
||||
midiInUnprepareHeader(dev->hmidiin, hdr, sizeof(MIDIHDR));
|
||||
}
|
||||
}
|
||||
|
||||
midiInClose(dev->hmidiin);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue