Default to FOURCC_DOS if no IOProc found.

This commit is contained in:
Christian Costa 2004-03-16 01:14:07 +00:00 committed by Alexandre Julliard
parent 4bbeb429c8
commit b3b3f4c0c3

View File

@ -633,7 +633,12 @@ HMMIO MMIO_Open(LPSTR szFileName, MMIOINFO* refmminfo, DWORD dwOpenFlags,
/* Handle any unhandled/error case. Assume DOS file */
if (wm->info.fccIOProc == 0)
wm->info.fccIOProc = FOURCC_DOS;
if (!(wm->ioProc = MMIO_FindProcNode(wm->info.fccIOProc))) goto error2;
if (!(wm->ioProc = MMIO_FindProcNode(wm->info.fccIOProc))) {
/* If not found, retry with FOURCC_DOS */
wm->info.fccIOProc = FOURCC_DOS;
if (!(wm->ioProc = MMIO_FindProcNode(wm->info.fccIOProc)))
goto error2;
}
wm->bTmpIOProc = FALSE;
}
/* if just the four character code is present, look up IO proc */