mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-22 18:59:08 +02:00
SynEdit: Improve d8e4b249c3
, initialize out variable. issue #41553
This commit is contained in:
parent
a0891522ed
commit
ebd7f56170
@ -1141,9 +1141,10 @@ end;
|
|||||||
|
|
||||||
function TSynEditStringList.GetPChar(ALineIndex: Integer; out ALen: Integer): PChar;
|
function TSynEditStringList.GetPChar(ALineIndex: Integer; out ALen: Integer): PChar;
|
||||||
begin
|
begin
|
||||||
ALen := 0;
|
if (ALineIndex = 0) and (Count = 0) then begin // simulate empty line
|
||||||
if (ALineIndex = 0) and (Count = 0) then // simulate empty line
|
ALen := 0;
|
||||||
Result := nil
|
Result := nil;
|
||||||
|
end
|
||||||
else
|
else
|
||||||
Result := FList.GetPChar(ALineIndex, ALen);
|
Result := FList.GetPChar(ALineIndex, ALen);
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user