"Gerald Pfeifer" gerald@pfeifer.com wrote:
The patch below fixes the following diagnostics (rightfully) issued by GCC 4.3 and later. If you prefer, we could use LOWORD everywhere, also for the case labels, but my current patch seems to be more natural.
decode.c:4365: warning: cast from pointer to integer of different size
--- decode.c 12 Oct 2007 10:24:15 -0000 1.87 +++ decode.c 14 Oct 2007 14:17:58 -0000 @@ -4360,103 +4360,103 @@ static CryptDecodeObjectExFunc CRYPT_Get } if (!HIWORD(lpszStructType)) {
switch (LOWORD(lpszStructType))
switch ((DWORD)lpszStructType)
Your fix still won't work for a 64-bit target. You would need to use ULONG_PTR cast for that. 'if (!HIWORD(lpszStructType))' line also doesn't look right in the 64-bit case.
dlls/crypt32/chain.c,CertVerifyCertificateChainPolicy() has the same problem.