this patch should fix some issues while pre-loading some information from MSACM drivers into a registry based cached namely, the lhacm.acm drivers now loads properly (bug was reported on #winehq a while back) A+ -- --------------- Eric Pouech (http://perso.wanadoo.fr/eric.pouech/) "The future will be better tomorrow", Vice President Dan Quayle
Name: msacm_cache ChangeLog: fixed bug in cache init GenDate: 2002/02/06 21:24:08 UTC ModifiedFiles: dlls/msacm/internal.c AddedFiles: =================================================================== RCS file: /home/cvs/cvsroot/wine/wine/dlls/msacm/internal.c,v retrieving revision 1.10 diff -u -u -r1.10 internal.c --- dlls/msacm/internal.c 22 May 2001 19:21:16 -0000 1.10 +++ dlls/msacm/internal.c 3 Feb 2002 20:01:09 -0000 @@ -70,11 +70,10 @@ */ static BOOL MSACM_FillCache(PWINE_ACMDRIVERID padid) { - HACMDRIVER had = 0; - int ntag; - ACMDRIVERDETAILSW add; - ACMFORMATDETAILSW aftd; - WAVEFORMATEX wfx; + HACMDRIVER had = 0; + int ntag; + ACMDRIVERDETAILSW add; + ACMFORMATTAGDETAILSW aftd; if (acmDriverOpen(&had, (HACMDRIVERID)padid, 0) != 0) return FALSE; @@ -95,20 +94,17 @@ padid->fdwSupport = add.fdwSupport; aftd.cbStruct = sizeof(aftd); - /* don't care about retrieving full struct... so a bare WAVEFORMATEX should do */ - aftd.pwfx = &wfx; - aftd.cbwfx = sizeof(wfx); - + for (ntag = 0; ntag < add.cFormatTags; ntag++) { - aftd.dwFormatIndex = ntag; - if (MSACM_Message(had, ACMDM_FORMAT_DETAILS, (LPARAM)&aftd, ACM_FORMATDETAILSF_INDEX)) { + aftd.dwFormatTagIndex = ntag; + if (MSACM_Message(had, ACMDM_FORMATTAG_DETAILS, (LPARAM)&aftd, ACM_FORMATTAGDETAILSF_INDEX)) { TRACE("IIOs (%s)\n", padid->pszDriverAlias); goto errCleanUp; } padid->aFormatTag[ntag].dwFormatTag = aftd.dwFormatTag; - padid->aFormatTag[ntag].cbwfx = aftd.cbwfx; + padid->aFormatTag[ntag].cbwfx = aftd.cbFormatSize; } - + acmDriverClose(had, 0); return TRUE;