Description
Title is not really descriptive but hope my follow explanation is:
Battery.inf is an INF file which has a [ClassInstall32.nt] section but which lacks a [ClassInstall32.nt.Services] section.
Battery.inf is tried to be installed via InstallSysSetupInfDevices() during the 2nd stage since it appears listed in [DeviceInfsToInstall] section of sysetup.inf.
InstallSysSetupInfDevices() ends calling SetupDiInstallClassExW to install battery.inf.
However, SetupDiInstallClassExW tries "forcely" to install the ClassInstall32.nt.Services section:
/* Install .Services section */
lstrcatW(SectionName, DotServices);
ret = SetupInstallServicesFromInfSectionExW( hInf, SectionName, 0, hDeviceInfo, NULL, NULL, NULL);
if (!ret) goto cleanup;
So if the INF, as this case is, does not have a .Services section, SetupDiInstallClassExW returns FALSE (BUG!!), this FALSE is sent upwards in the call chain, making InstallSysSetupInfDevices() fail and hence 2nd stage fails with a FATAL error.
For curious ones: Why we don't have a FATAL ERROR right now?
Basically because this bug is hidden by another bug in SetupInstallServicesFromInfSectionExW reported in CORE-9398 Fixing SetupInstallServicesFromInfSectionExW bug has led me to hit this bug.
(Basically right now the Reactos SetupInstallServicesFromInfSectionExW returns TRUE even if the Section does not exist, hidden the bug, while Windows counterpart fails. Testcases provided in CORE-9398)
Attachments
Issue Links
- blocks
-
CORE-9398 PATCH: Several fixes for SetupInstallServicesFromInfSectionExW
- Open