From b2371e5d713eda3a8f4ff2dec086233c9657e2ca Mon Sep 17 00:00:00 2001 From: marco Date: Sat, 17 Apr 2021 14:30:42 +0000 Subject: * Apply fix from bug #0038734 from Andrea Mauri to update vpbyte after fillbuffer in a loop. The second instance of fillbuffer is safe, because it is at the procedure exit, and vpbyte is a local variable. git-svn-id: https://svn.freepascal.org/svn/fpc/trunk@49219 3ad0048d-3df7-0310-abae-a5850022a9f2 --- packages/fcl-base/src/streamex.pp | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/fcl-base/src/streamex.pp b/packages/fcl-base/src/streamex.pp index 92684d57b5..a15db45e91 100644 --- a/packages/fcl-base/src/streamex.pp +++ b/packages/fcl-base/src/streamex.pp @@ -432,6 +432,7 @@ begin Move(FBuffer[VPosition], AString[Succ(VStrLength)], VLength); end; FillBuffer; + VPByte := @FBuffer[FBufferPosition]; VPosition := FBufferPosition; end; until (FBufferPosition = FBufferRead) or (VPByte^ in [10, 13]); -- cgit v1.2.1