mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-11 18:25:58 +02:00
* patch from Bart for mantis 35271 committed. Avoid create directory block when extractfilepath(<filename>) is empty
git-svn-id: trunk@41860 -
This commit is contained in:
parent
b9e3a0692c
commit
93a3764cd5
@ -499,7 +499,7 @@ Procedure CreateFile;
|
|||||||
|
|
||||||
Var
|
Var
|
||||||
Fout : Text;
|
Fout : Text;
|
||||||
S,BFN : String;
|
S,BFN,ODir : String;
|
||||||
I : Integer;
|
I : Integer;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
@ -527,7 +527,8 @@ begin
|
|||||||
else
|
else
|
||||||
Writeln(Format(SBackupCreated,[ExtractFileName(OutputFileName),ExtractFileName(BFN)]));
|
Writeln(Format(SBackupCreated,[ExtractFileName(OutputFileName),ExtractFileName(BFN)]));
|
||||||
end;
|
end;
|
||||||
if (OutputFileName<>'') and not DirectoryExists(ExtractFilePath(OutputFileName)) then
|
ODir:=ExtractFilePath(OutputFileName);
|
||||||
|
if (OutputFileName<>'') and (ODir<>'') and not DirectoryExists(ODir) then
|
||||||
begin
|
begin
|
||||||
if CreateDir then
|
if CreateDir then
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user