[PATCH 7/8] dllhost: Periodically call CoFreeUnusedLibraries().
Dmitry Timoshkov
dmitry at baikal.ru
Tue Feb 22 04:02:52 CST 2022
Signed-off-by: Dmitry Timoshkov <dmitry at baikal.ru>
---
programs/dllhost/dllhost.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/programs/dllhost/dllhost.c b/programs/dllhost/dllhost.c
index 8baf5c7c371..2c4d30d2224 100644
--- a/programs/dllhost/dllhost.c
+++ b/programs/dllhost/dllhost.c
@@ -364,7 +364,8 @@ int WINAPI wWinMain(HINSTANCE hinst, HINSTANCE previnst, LPWSTR cmdline, int sho
goto cleanup;
}
- WaitForSingleObject(surrogate.event, INFINITE);
+ while (WaitForSingleObject(surrogate.event, 30000) != WAIT_OBJECT_0)
+ CoFreeUnusedLibraries();
}
cleanup:
--
2.35.1
More information about the wine-devel
mailing list