Dmitry Timoshkov dmitry@codeweavers.com writes:
- count = WDML_CritSect.RecursionCount;
- for (i = 0; i < count; i++)
LeaveCriticalSection(&WDML_CritSect);
You don't want to do that sort of thing. You should fix the callers to not hold the crit section, instead of silently releasing it behind their backs.