mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-10-01 08:19:14 +02:00
+ added a define FINDHANDLE_IS_POINTER that indicates that on the current
platform SysUtils.TSearchRec.FileHandle is a Pointer, instead of THandle. I didn't introduce a TFindHandle type, because I didn't want to add yet another publicly visible type in the SysUtils interface. git-svn-id: trunk@28449 -
This commit is contained in:
parent
fee1632b42
commit
f5c1751be5
@ -433,11 +433,9 @@ type
|
||||
indication enough that you should not touch it }
|
||||
Name_do_not_touch : RawByteString;
|
||||
ExcludeAttr : Longint;
|
||||
FindHandle : {$ifdef FINDHANDLE_IS_POINTER}Pointer{$else}THandle{$endif};
|
||||
{$ifdef unix}
|
||||
FindHandle : Pointer;
|
||||
Mode : TMode;
|
||||
{$else unix}
|
||||
FindHandle : THandle;
|
||||
{$endif unix}
|
||||
{$ifdef USEFINDDATA}
|
||||
FindData : TFindData;
|
||||
@ -455,7 +453,7 @@ Function InternalFindFirst (Const Path : UnicodeString; Attr : Longint; out Rslt
|
||||
Function InternalFindNext (var Rslt : TAbstractSearchRec; var Name : UnicodeString) : Longint; forward;
|
||||
{$endif SYSUTILS_HAS_UNICODESTR_FILEUTIL_IMPL}
|
||||
|
||||
procedure InternalFindClose(var Handle: {$ifdef unix}Pointer{$else}THandle{$endif}{$ifdef USEFINDDATA};var FindData: TFindData{$endif}); forward;
|
||||
procedure InternalFindClose(var Handle: {$ifdef FINDHANDLE_IS_POINTER}Pointer{$else}THandle{$endif}{$ifdef USEFINDDATA};var FindData: TFindData{$endif}); forward;
|
||||
|
||||
|
||||
{$ifndef SYSUTILS_HAS_ANSISTR_FILEUTIL_IMPL}
|
||||
|
@ -16,6 +16,11 @@
|
||||
Type
|
||||
|
||||
|
||||
// Some operating systems need FindHandle to be a Pointer
|
||||
{$if defined(unix)}
|
||||
{$define FINDHANDLE_IS_POINTER}
|
||||
{$endif}
|
||||
|
||||
// Some operating systems need extra find data.
|
||||
{$if defined(Win32) or defined(WinCE) or defined(Win64)}
|
||||
{$define USEFINDDATA}
|
||||
@ -62,11 +67,9 @@ Type
|
||||
Attr : Longint;
|
||||
Name : RawByteString;
|
||||
ExcludeAttr : Longint;
|
||||
FindHandle : {$ifdef FINDHANDLE_IS_POINTER}Pointer{$else}THandle{$endif};
|
||||
{$ifdef unix}
|
||||
FindHandle : Pointer;
|
||||
Mode : TMode;
|
||||
{$else unix}
|
||||
FindHandle : THandle;
|
||||
{$endif unix}
|
||||
{$IFDEF USEFINDDATA}
|
||||
FindData : TFindData;
|
||||
|
Loading…
Reference in New Issue
Block a user