From 4b6368c0e25e6da5676b308f28818a61622db6bf Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Sun, 28 Oct 2007 02:49:19 +0200 Subject: [PATCH] cryptnet: Fix compilation on systems that don't support nameless structs. --- dlls/cryptnet/cryptnet_main.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index b83adb850e3..487da9df170 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -23,6 +23,7 @@ #include #define NONAMELESSUNION +#define NONAMELESSSTRUCT #include "windef.h" #include "wine/debug.h" @@ -353,7 +354,7 @@ static BOOL CRYPT_GetObjectFromFile(HANDLE hFile, PCRYPT_BLOB_ARRAY pObject) if ((ret = GetFileSizeEx(hFile, &size))) { - if (size.HighPart) + if (size.u.HighPart) { WARN("file too big\n"); SetLastError(ERROR_INVALID_DATA); @@ -363,11 +364,11 @@ static BOOL CRYPT_GetObjectFromFile(HANDLE hFile, PCRYPT_BLOB_ARRAY pObject) { CRYPT_DATA_BLOB blob; - blob.pbData = CryptMemAlloc(size.LowPart); + blob.pbData = CryptMemAlloc(size.u.LowPart); if (blob.pbData) { - blob.cbData = size.LowPart; - ret = ReadFile(hFile, blob.pbData, size.LowPart, &blob.cbData, + blob.cbData = size.u.LowPart; + ret = ReadFile(hFile, blob.pbData, size.u.LowPart, &blob.cbData, NULL); if (ret) {