Module: wine Branch: master Commit: 516f68b64f78c26adc2005b03528cf3336d4a115 URL: https://gitlab.winehq.org/wine/wine/-/commit/516f68b64f78c26adc2005b03528cf3...
Author: Lorenzo Ferrillo lorenzofersteam@live.it Date: Sun Sep 10 18:15:21 2023 +0200
ole32: Add debug info to RunningObjectTable critical section.
So it's possible to easily debug deadlocks involving the Internal ROT object
Signed-off-by: Lorenzo Ferrillo lorenzofersteam@live.it
---
dlls/ole32/moniker.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/dlls/ole32/moniker.c b/dlls/ole32/moniker.c index f9f266044e4..b81033c6c4e 100644 --- a/dlls/ole32/moniker.c +++ b/dlls/ole32/moniker.c @@ -707,10 +707,19 @@ static const IRunningObjectTableVtbl VT_RunningObjectTableImpl = RunningObjectTableImpl_EnumRunning };
+static RunningObjectTableImpl rot; + +static RTL_CRITICAL_SECTION_DEBUG critsect_debug = +{ + 0, 0, &rot.lock, + { &critsect_debug.ProcessLocksList, &critsect_debug.ProcessLocksList }, + 0, 0, { (DWORD_PTR)(__FILE__ ": RunningObjectTable_section") } +}; + static RunningObjectTableImpl rot = { .IRunningObjectTable_iface.lpVtbl = &VT_RunningObjectTableImpl, - .lock.LockCount = -1, + .lock = { &critsect_debug, -1, 0, 0, 0, 0 }, .rot = LIST_INIT(rot.rot), };