mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-21 12:49:33 +02:00
fcl-js: fixed warnings
git-svn-id: trunk@39437 -
This commit is contained in:
parent
b2e349cecf
commit
620888b54e
@ -953,6 +953,7 @@ var
|
||||
P: TJSONParser;
|
||||
Data: TJSONData;
|
||||
begin
|
||||
s:='';
|
||||
SetLength(s,aStream.Size-aStream.Position);
|
||||
if s<>'' then
|
||||
aStream.Read(s[1],length(s));
|
||||
|
@ -226,6 +226,7 @@ end;
|
||||
|
||||
function TBufferWriter.GetAsAnsistring: AnsiString;
|
||||
begin
|
||||
Result:='';
|
||||
SetLength(Result,BufferLength);
|
||||
if (BufferLength>0) then
|
||||
Move(FBuffer[0],Result[1],BufferLength);
|
||||
@ -248,6 +249,7 @@ Var
|
||||
|
||||
begin
|
||||
SL:=BufferLength div SizeOf(UnicodeChar); // Silently ignores last byte
|
||||
Result:='';
|
||||
SetLength(Result,SL);
|
||||
if (SL>0) then
|
||||
Move(FBuffer[0],Result[1],SL*SizeOf(UnicodeChar));
|
||||
|
Loading…
Reference in New Issue
Block a user