diff --git a/reactos/services/umpnpmgr/umpnpmgr.c b/reactos/services/umpnpmgr/umpnpmgr.c index d76a342cb1e..1791a4d26d9 100644 --- a/reactos/services/umpnpmgr/umpnpmgr.c +++ b/reactos/services/umpnpmgr/umpnpmgr.c @@ -933,10 +933,11 @@ SetupIsActive(VOID) if (rc != ERROR_SUCCESS) goto cleanup; + size = sizeof(DWORD); rc = RegQueryValueExW(hKey, L"SystemSetupInProgress", NULL, ®Type, (LPBYTE)&active, &size); if (rc != ERROR_SUCCESS) goto cleanup; - if (regType != REG_DWORD) + if (regType != REG_DWORD || size != sizeof(DWORD)) goto cleanup; ret = (active != 0);