* Define INVALID_HANDLE_VALUE for Delphi compatibility

This commit is contained in:
Michaël Van Canneyt 2023-11-29 15:03:12 +01:00
parent 54b8de47f0
commit ff8511f2f1
2 changed files with 9 additions and 0 deletions

View File

@ -473,3 +473,8 @@ Type
Function GetCompiledArchitecture : TOSVersion.TArchitecture;
Function GetCompiledPlatform : TOSVersion.TPlatform;
{$IFNDEF HAS_INVALIDHANDLE}
const
INVALID_HANDLE_VALUE = DWORD(-1);
{$ENDIF}

View File

@ -49,6 +49,10 @@ uses
{$DEFINE OS_FILESETDATEBYNAME}
{$DEFINE HAS_FILEGETDATETIMEINFO}
{$DEFINE HAS_INVALIDHANDLE}
const
INVALID_HANDLE_VALUE = {$IFDEF FPC_DOTTEDUNITS}WinApi.{$ENDIF}Windows.INVALID_HANDLE_VALUE;
// this target has an fileflush implementation, don't include dummy
{$DEFINE SYSUTILS_HAS_FILEFLUSH_IMPL}