Ignore:
Timestamp:
Feb 8, 2012, 1:05:59 PM (13 years ago)
Author:
chronos
Message:
  • Fixed: Error in writing same object to TListObject item cause freeing of object.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • Generics/TemplateGenerics/Generic/GenericListObject.inc

    r312 r325  
    7575procedure TGListObject.Put(Index: TGListIndex; const AValue: TGListItem);
    7676begin
    77   if OwnsObjects then FItems[Index].Free;
     77  if OwnsObjects and (FItems[Index] <> AValue) then FItems[Index].Free;
    7878  inherited Put(Index, AValue);
    7979end;
Note: See TracChangeset for help on using the changeset viewer.