mcicda: Prevent crash when closing while playing.

This commit is contained in:
Jörg Höhle 2010-03-10 20:52:46 +01:00 committed by Alexandre Julliard
parent 22569e6dce
commit 3f529a6e70
1 changed files with 2 additions and 0 deletions

View File

@ -483,6 +483,8 @@ static DWORD MCICDA_Close(UINT wDevID, DWORD dwParam, LPMCI_GENERIC_PARMS lpParm
if (wmcda == NULL) return MCIERR_INVALID_DEVICE_ID;
MCICDA_Stop(wDevID, MCI_WAIT, NULL);
if (--wmcda->nUseCount == 0) {
CloseHandle(wmcda->handle);
}