krnl386.exe: Cap GetFreeSpace value to 2GB.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46962
Signed-off-by: Akihiro Sagawa <sagawa.aki@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Akihiro Sagawa 2021-02-20 21:26:27 +09:00 committed by Alexandre Julliard
parent b9ceaa6fed
commit eca2bfd071
1 changed files with 1 additions and 1 deletions

View File

@ -750,7 +750,7 @@ DWORD WINAPI GetFreeSpace16( UINT16 wFlags )
{
MEMORYSTATUS ms;
GlobalMemoryStatus( &ms );
return ms.dwAvailVirtual;
return min( ms.dwAvailVirtual, MAXLONG );
}
/***********************************************************************