mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-07 18:58:04 +02:00
ProjectTemplates: Prevent wrongly replacing "project" in .lpi file. Issue #39467.
This commit is contained in:
parent
dda3cc7c81
commit
dda96a3864
@ -9,7 +9,7 @@ uses
|
||||
// LCL
|
||||
LResources, Forms, Controls, Graphics, Dialogs,
|
||||
// LazUtils
|
||||
LazFileUtils,
|
||||
LazFileUtils, LazLoggerBase,
|
||||
// IdeIntf
|
||||
ProjectIntf, NewItemIntf, MenuIntf, BaseIDEIntf, LazIDEIntf,
|
||||
// ProjectTemplates
|
||||
@ -113,7 +113,8 @@ var
|
||||
sl: TStringList;
|
||||
i: Integer;
|
||||
begin
|
||||
if not FileExistsUTF8(FN) then
|
||||
//DebugLn(['FileReplaceText: From=', AFrom, ', To=', ATo]);
|
||||
if (not FileExistsUTF8(FN)) or (AFrom='') then
|
||||
exit;
|
||||
sl:=TStringList.Create;
|
||||
try
|
||||
|
@ -254,7 +254,7 @@ begin
|
||||
inherited Create(ACollection);
|
||||
FVariables:=TStringList.Create;
|
||||
FFiles:=TStringList.Create;
|
||||
FProjectFile:='project' // Do not localize
|
||||
FProjectFile:='';
|
||||
end;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user