codetools: fixed mem leak FPM.UnitToSrc

git-svn-id: trunk@60711 -
This commit is contained in:
mattias 2019-03-17 20:50:37 +00:00
parent 5a253cd424
commit 507da49bf0

View File

@ -2089,6 +2089,7 @@ begin
if FPMSourcePath<>'' then begin
//debugln(['GatherUnitsInFPMSources ',FPMFilename,' ',FPMSourcePath]);
FreeAndNil(FPM.UnitToSrc);
FPM.UnitToSrc:=GatherUnitSourcesInDirectory(FPMSourcePath,3);
end;
end;
@ -8144,7 +8145,7 @@ begin
FreeAndNil(Units);
FreeAndNil(Includes);
FreeAndNil(UnitToFPM);
FreeAndNil(FPMNameToFPM);
FreeAndNil(FPMNameToFPM); // this frees the FPMs
end;
function TPCTargetConfigCache.Equals(Item: TPCTargetConfigCache;