AW: [fpc-devel] MemoryLeak with AS Operator
Helmut Hartl
helmut.hartl at firmos.at
Wed Jul 26 08:38:31 CEST 2006
Hello,
can anyone give me a hint where to search for the "AS" compiler problem.
We tried to workaround that in ZEOS Code and gave up, as we are not able
to find all Memory holes and pinpoint them.
With 2.02 we have the problem that the TDataset has different behaviour
than in Delphi (Datetime).
No we are making production code with a self patched 2.02 release
(TDataset from 2.04) but that's no good solution.
Thanks,
helmut
> Hello,
> In testing upcoming 2.0.4 release i found an incompatibility/memory
> leak which is present in fpc versions greater 2.0.2.
> ...
> The following code runs differently on compiler versions greater 2.0.2
>
> function TTestCollection.Add(const
> Item:IInterface): Integer; begin
>
> FList^[0] := Item as IInterface; // (1)
> //FList^[0] := Item; // (2)
>
> end;
>
> (1) => Original Code No Memory Leak with FPC=2.0.2 but with > 2.0.2
> (2) => No Memory Leak
>
> Reported with a demo program as Bug 7174.
>
http://www.freepascal.org/mantis/bug_view_advanced_page.php?bug_id=7174
More information about the fpc-devel
mailing list