mirror of
https://github.com/reactos/wine.git
synced 2025-02-21 05:11:57 +00:00
mciseq: Fix memory leak when MCI_OPEN fails.
This commit is contained in:
parent
1c30b894ec
commit
2b54cb5493
@ -797,6 +797,10 @@ static DWORD MIDI_mciOpen(WINE_MCIMIDI* wmm, DWORD dwFlags, LPMCI_OPEN_PARMSW lp
|
||||
if (wmm->hFile != 0)
|
||||
mmioClose(wmm->hFile, 0);
|
||||
wmm->hFile = 0;
|
||||
HeapFree(GetProcessHeap(), 0, wmm->tracks);
|
||||
HeapFree(GetProcessHeap(), 0, wmm->lpstrElementName);
|
||||
HeapFree(GetProcessHeap(), 0, wmm->lpstrCopyright);
|
||||
HeapFree(GetProcessHeap(), 0, wmm->lpstrName);
|
||||
} else {
|
||||
wmm->dwPositionMS = 0;
|
||||
wmm->dwStatus = MCI_MODE_STOP;
|
||||
|
Loading…
x
Reference in New Issue
Block a user