see comment:
destructor TIPTCTag.Destroy;
begin
if (FSection <> NIL) AND (FSection.FTags <> NIL) { I had a crash because the second check was missing. Reaseon: FTags are already freed by TIPTCSection.Destroy }
then FSection.FTags.Extract(Self);
ReallocMem(FData, 0);
inherited;
end;
how I discovered the bug? with some help from FreeAndNil.
see comment:
destructor TIPTCTag.Destroy;
begin
if (FSection <> NIL) AND (FSection.FTags <> NIL) { I had a crash because the second check was missing. Reaseon: FTags are already freed by TIPTCSection.Destroy }
then FSection.FTags.Extract(Self);
ReallocMem(FData, 0);
inherited;
end;
how I discovered the bug? with some help from FreeAndNil.