mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-12-06 04:47:17 +01:00
+ Fixed applyupdates for empty datasets
git-svn-id: trunk@2440 -
This commit is contained in:
parent
66bc185aa7
commit
bc4e23b9c2
@ -605,8 +605,10 @@ var SaveBookmark : Integer;
|
||||
|
||||
begin
|
||||
CheckBrowseMode;
|
||||
if IsEmpty then exit;
|
||||
SaveBookMark := GetRecNo;
|
||||
|
||||
// There is no bookmark available if the dataset is empty
|
||||
if not IsEmpty then
|
||||
SaveBookMark := GetRecNo;
|
||||
|
||||
r := 0;
|
||||
while r < Length(FUpdateBuffer) do
|
||||
@ -652,12 +654,13 @@ begin
|
||||
end;
|
||||
inc(r);
|
||||
end;
|
||||
if not GetDeleted(pbyte(FBBuffers[savebookmark])) then
|
||||
if not IsEmpty then
|
||||
begin
|
||||
InternalGotoBookMark(@SaveBookMark);
|
||||
Resync([rmExact,rmCenter]);
|
||||
end;
|
||||
|
||||
end
|
||||
else
|
||||
InternalFirst;
|
||||
end;
|
||||
|
||||
procedure TBufDataset.InternalPost;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user