mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 03:46:10 +02:00
* Keep old behaviour, but keep issue #40898 solved
This commit is contained in:
parent
97ad8fafd8
commit
58560d333e
@ -1946,11 +1946,16 @@ begin
|
|||||||
DupIgnore : Exit;
|
DupIgnore : Exit;
|
||||||
DupError : Error(SDuplicateString,0)
|
DupError : Error(SDuplicateString,0)
|
||||||
end;
|
end;
|
||||||
// Avoid crash in lazarus
|
InsertItem (Result,S);
|
||||||
if Assigned(aObject) then
|
if (aObject<>Nil) then
|
||||||
InsertItem (Result,S,AObject)
|
begin
|
||||||
else
|
BeginUpdate;
|
||||||
InsertItem (Result,S);
|
try
|
||||||
|
Objects[Result]:=AObject;
|
||||||
|
finally
|
||||||
|
EndUpdate;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TStringList.Add(const S: string): Integer;
|
function TStringList.Add(const S: string): Integer;
|
||||||
|
Loading…
Reference in New Issue
Block a user