mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 01:45:40 +00:00
Temp fix for GlobalMemoryStatus, pleas test.
svn path=/trunk/; revision=9569
This commit is contained in:
parent
0d5d9a4b7d
commit
9666870f38
1 changed files with 6 additions and 3 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: global.c,v 1.23 2004/04/22 02:20:52 jimtabor Exp $
|
/* $Id: global.c,v 1.24 2004/05/31 16:54:04 jimtabor Exp $
|
||||||
*
|
*
|
||||||
* Win32 Global/Local heap functions (GlobalXXX, LocalXXX).
|
* Win32 Global/Local heap functions (GlobalXXX, LocalXXX).
|
||||||
* These functions included in Win32 for compatibility with 16 bit Windows
|
* These functions included in Win32 for compatibility with 16 bit Windows
|
||||||
|
@ -453,17 +453,20 @@ VOID STDCALL
|
||||||
GlobalMemoryStatus(LPMEMORYSTATUS lpBuffer)
|
GlobalMemoryStatus(LPMEMORYSTATUS lpBuffer)
|
||||||
{
|
{
|
||||||
MEMORYSTATUSEX lpBufferEx;
|
MEMORYSTATUSEX lpBufferEx;
|
||||||
|
#if 0
|
||||||
if (lpBuffer->dwLength != sizeof(MEMORYSTATUS))
|
if (lpBuffer->dwLength != sizeof(MEMORYSTATUS))
|
||||||
{
|
{
|
||||||
SetLastError(ERROR_INVALID_PARAMETER);
|
SetLastError(ERROR_INVALID_PARAMETER);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
lpBufferEx.dwLength = sizeof(MEMORYSTATUSEX);
|
lpBufferEx.dwLength = sizeof(MEMORYSTATUSEX);
|
||||||
|
|
||||||
if (GlobalMemoryStatusEx(&lpBufferEx))
|
if (GlobalMemoryStatusEx(&lpBufferEx))
|
||||||
{
|
{
|
||||||
|
|
||||||
|
lpBuffer->dwLength = sizeof(MEMORYSTATUS);
|
||||||
|
|
||||||
lpBuffer->dwMemoryLoad = lpBufferEx.dwMemoryLoad;
|
lpBuffer->dwMemoryLoad = lpBufferEx.dwMemoryLoad;
|
||||||
lpBuffer->dwTotalPhys = lpBufferEx.ullTotalPhys;
|
lpBuffer->dwTotalPhys = lpBufferEx.ullTotalPhys;
|
||||||
lpBuffer->dwAvailPhys = lpBufferEx.ullAvailPhys;
|
lpBuffer->dwAvailPhys = lpBufferEx.ullAvailPhys;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue