[User32] Fix null return.

See CORE-16769.
This commit is contained in:
jimtabor 2020-03-28 14:03:15 -05:00
parent 7481bda679
commit d8add40e89

View file

@ -159,7 +159,8 @@ RtlGetExpWinVer( HMODULE hModule )
if ( hModule && !((ULONG_PTR)hModule >> 16))
{
pinth = RtlImageNtHeader( hModule );
if ( pinth )
{
dwMajorVersion = pinth->OptionalHeader.MajorSubsystemVersion;
if ( dwMajorVersion == 1 )
@ -171,6 +172,7 @@ RtlGetExpWinVer( HMODULE hModule )
dwMinorVersion = pinth->OptionalHeader.MinorSubsystemVersion;
}
}
}
return MAKELONG(MAKEWORD(dwMinorVersion, dwMajorVersion), 0);
}