https://git.reactos.org/?p=reactos.git;a=commitdiff;h=e6568af2d34fbd9e90ab0…
commit e6568af2d34fbd9e90ab029a442a18075c0dcc85
Author: Mark Jansen <mark.jansen(a)reactos.org>
AuthorDate: Mon Nov 15 19:53:21 2021 +0100
Commit: Mark Jansen <mark.jansen(a)reactos.org>
CommitDate: Fri Dec 31 21:26:18 2021 +0100
[SYSSETUP] Register type libraries before signaling we are done
This prevents a race condition, where hSysSetupInf could be closed before all type
libraries are registered
---
dll/win32/syssetup/wizard.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/dll/win32/syssetup/wizard.c b/dll/win32/syssetup/wizard.c
index efddcfd6b1d..77db90686f2 100644
--- a/dll/win32/syssetup/wizard.c
+++ b/dll/win32/syssetup/wizard.c
@@ -2170,6 +2170,12 @@ RegistrationProc(LPVOID Parameter)
RegistrationNotify.Progress = RegistrationData->DllCount;
RegistrationNotify.ActivityID = IDS_REGISTERING_COMPONENTS;
RegistrationNotify.CurrentItem = NULL;
+
+ RegisterTypeLibraries(hSysSetupInf, L"TypeLibraries");
+
+ // FIXME: Move this call to a separate cleanup page!
+ RtlCreateBootStatusDataFile();
+
SendMessage(RegistrationData->hwndDlg, PM_REGISTRATION_NOTIFY,
1, (LPARAM) &RegistrationNotify);
if (NULL != RegistrationNotify.ErrorMessage &&
@@ -2181,11 +2187,6 @@ RegistrationProc(LPVOID Parameter)
SetupTermDefaultQueueCallback(RegistrationData->DefaultContext);
HeapFree(GetProcessHeap(), 0, RegistrationData);
- RegisterTypeLibraries(hSysSetupInf, L"TypeLibraries");
-
- // FIXME: Move this call to a separate cleanup page!
- RtlCreateBootStatusDataFile();
-
return 0;
}