Data update
This commit is contained in:
parent
81fd053722
commit
52a6ef48dd
10248 changed files with 63654 additions and 6775 deletions
24
Task/Secure-temporary-file/Delphi/secure-temporary-file.pas
Normal file
24
Task/Secure-temporary-file/Delphi/secure-temporary-file.pas
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
program Secure_temporary_file;
|
||||
|
||||
{$APPTYPE CONSOLE}
|
||||
|
||||
uses
|
||||
System.SysUtils,
|
||||
System.IOUtils;
|
||||
|
||||
var
|
||||
FileName, buf: string;
|
||||
|
||||
begin
|
||||
FileName := TPath.GetTempFileName;
|
||||
with TFile.Open(FileName, TFileMode.fmCreate, TFileAccess.faReadWrite,
|
||||
Tfileshare.fsNone) do
|
||||
begin
|
||||
buf := 'This is a exclusive temp file';
|
||||
Write(buf[1], buf.Length * sizeof(char));
|
||||
Free;
|
||||
end;
|
||||
|
||||
writeln(FileName);
|
||||
Readln;
|
||||
end.
|
||||
Loading…
Add table
Add a link
Reference in a new issue