Question about deadlock in winmm
Lately I'm seeing a lot of deadlocks in wine's sound system. Most notably winealsa. But the code in question affects all (in my case oss since it's working better for me then others). I'm not sure what exactly happens (deadlock because of race condition or else) but code bellow deadlocks with other heap functions (like GetHeap). Removing HeapValidate didn't cause any problems for as of yet. And I haven't seen a single deadlock here at all. Is there are reasons we perform this heap validation here? Could someone comment on this? If someone interested I could reproduce backtrace of the deadlock. -- Best regards, Vitaliy Index: dlls/winmm/lolvldrv.c =================================================================== RCS file: /home/wine/wine/dlls/winmm/lolvldrv.c,v retrieving revision 1.68 diff -u -p -r1.68 lolvldrv.c --- dlls/winmm/lolvldrv.c 22 Jun 2005 11:59:43 -0000 1.68 +++ dlls/winmm/lolvldrv.c 29 Jun 2005 14:54:42 -0000 @@ -441,7 +441,7 @@ LPWINE_MLD MMDRV_Get(HANDLE _hndl, UINT hndl = hndl & ~0x8000; if (hndl < sizeof(MM_MLDrvs) / sizeof(MM_MLDrvs[0])) { mld = MM_MLDrvs[hndl]; - if (!mld || !HeapValidate(GetProcessHeap(), 0, mld) || mld->type != type) + if (!mld || mld->type != type) mld = NULL; } hndl = hndl | 0x8000;
participants (1)
-
Vitaliy Margolen