Explorar el Código

* don't assume stream is at position=0 mantis #0037332

git-svn-id: trunk@45776 -
marco hace 5 años
padre
commit
515b92263f
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      packages/fcl-json/src/jsonscanner.pp

+ 1 - 1
packages/fcl-json/src/jsonscanner.pp

@@ -146,7 +146,7 @@ Var
 
 begin
   S:='';
-  SetLength(S,Source.Size);
+  SetLength(S,Source.Size-Source.Position);
   if Length(S)>0 then
     Source.ReadBuffer(S[1],Length(S));
   Create(S,AOptions)