Free should not happen when still playing.
This commit is contained in:
parent
a3c45689b4
commit
9d2e09851b
|
@ -2357,6 +2357,7 @@ UINT WINAPI waveOutClose(HWAVEOUT hWaveOut)
|
||||||
return MMSYSERR_INVALHANDLE;
|
return MMSYSERR_INVALHANDLE;
|
||||||
|
|
||||||
dwRet = MMDRV_Close(wmld, WODM_CLOSE);
|
dwRet = MMDRV_Close(wmld, WODM_CLOSE);
|
||||||
|
if (dwRet != WAVERR_STILLPLAYING)
|
||||||
MMDRV_Free(hWaveOut, wmld);
|
MMDRV_Free(hWaveOut, wmld);
|
||||||
|
|
||||||
return dwRet;
|
return dwRet;
|
||||||
|
@ -2706,6 +2707,7 @@ UINT WINAPI waveInClose(HWAVEIN hWaveIn)
|
||||||
return MMSYSERR_INVALHANDLE;
|
return MMSYSERR_INVALHANDLE;
|
||||||
|
|
||||||
dwRet = MMDRV_Message(wmld, WIDM_CLOSE, 0L, 0L, TRUE);
|
dwRet = MMDRV_Message(wmld, WIDM_CLOSE, 0L, 0L, TRUE);
|
||||||
|
if (dwRet != WAVERR_STILLPLAYING)
|
||||||
MMDRV_Free(hWaveIn, wmld);
|
MMDRV_Free(hWaveIn, wmld);
|
||||||
return dwRet;
|
return dwRet;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue