* Add Flush method to TFileStream. Fix issue #39619

This commit is contained in:
Michaël Van Canneyt 2022-03-10 09:35:18 +01:00
parent 82ccc863ef
commit 5ca52bcab1
2 changed files with 6 additions and 0 deletions

View File

@ -1187,6 +1187,7 @@ type
constructor Create(const AFileName: string; Mode: Word);
constructor Create(const AFileName: string; Mode: Word; Rights: Cardinal);
destructor Destroy; override;
Function Flush : Boolean;
property FileName : String Read FFilename;
end;

View File

@ -1336,6 +1336,11 @@ begin
FileClose(FHandle);
end;
function TFileStream.Flush : Boolean;
begin
Result:=FileFlush(Handle);
end;
{****************************************************************************}
{* TCustomMemoryStream *}
{****************************************************************************}