Commit d40e0033 authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

winmm: MMIO_ALLOCBUF is ignored if mmioOpen gets a valid buffer.

Existing tests show that MMIO_ALLOCBUF flag is dropped if a valid buffer is being passed to mmioOpen, that means the buffer is valid in that case.
parent 94d753c6
...@@ -667,10 +667,11 @@ HMMIO MMIO_Open(LPSTR szFileName, MMIOINFO* refmminfo, DWORD dwOpenFlags, ...@@ -667,10 +667,11 @@ HMMIO MMIO_Open(LPSTR szFileName, MMIOINFO* refmminfo, DWORD dwOpenFlags,
refmminfo->wErrorRet = MMIO_SetBuffer(wm, refmminfo->pchBuffer, refmminfo->cchBuffer, 0); refmminfo->wErrorRet = MMIO_SetBuffer(wm, refmminfo->pchBuffer, refmminfo->cchBuffer, 0);
if (refmminfo->wErrorRet != MMSYSERR_NOERROR) if (refmminfo->wErrorRet != MMSYSERR_NOERROR)
goto error1; goto error1;
if (wm->info.fccIOProc == FOURCC_MEM)
wm->bBufferLoaded = TRUE;
} }
if (wm->info.fccIOProc == FOURCC_MEM && !(wm->info.dwFlags & MMIO_ALLOCBUF))
wm->bBufferLoaded = TRUE;
/* see mmioDosIOProc for that one */ /* see mmioDosIOProc for that one */
wm->info.adwInfo[0] = refmminfo->adwInfo[0]; wm->info.adwInfo[0] = refmminfo->adwInfo[0];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment