mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 03:09:36 +02:00
Some fixes from Luiz Americo, fixes destroy
This commit is contained in:
parent
30873fc9a8
commit
7452bd955c
@ -256,11 +256,11 @@ end;
|
|||||||
|
|
||||||
destructor TSqliteDataset.Destroy;
|
destructor TSqliteDataset.Destroy;
|
||||||
begin
|
begin
|
||||||
|
inherited Destroy;
|
||||||
FUpdatedItems.Destroy;
|
FUpdatedItems.Destroy;
|
||||||
FAddedItems.Destroy;
|
FAddedItems.Destroy;
|
||||||
FDeletedItems.Destroy;
|
FDeletedItems.Destroy;
|
||||||
FOrphanItems.Destroy;
|
FOrphanItems.Destroy;
|
||||||
inherited Destroy;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSqliteDataset.DisposeLinkedList;
|
procedure TSqliteDataset.DisposeLinkedList;
|
||||||
@ -560,6 +560,7 @@ var
|
|||||||
TempStr:String;
|
TempStr:String;
|
||||||
ActiveItem:PDataRecord;
|
ActiveItem:PDataRecord;
|
||||||
begin
|
begin
|
||||||
|
if FRecordCount = 0 then exit; //avoid exception in win32 + lcl + TDbEdit
|
||||||
ActiveItem:=PPDataRecord(ActiveBuffer)^;
|
ActiveItem:=PPDataRecord(ActiveBuffer)^;
|
||||||
if (ActiveItem <> FCacheItem) and (FUpdatedItems.IndexOf(ActiveItem) = -1) and (FAddedItems.IndexOf(ActiveItem) = -1) then
|
if (ActiveItem <> FCacheItem) and (FUpdatedItems.IndexOf(ActiveItem) = -1) and (FAddedItems.IndexOf(ActiveItem) = -1) then
|
||||||
FUpdatedItems.Add(ActiveItem);
|
FUpdatedItems.Add(ActiveItem);
|
||||||
|
Loading…
Reference in New Issue
Block a user