mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 19:09:23 +02:00
* changed InputFileBufSize from 32kb to 32kb+1byte, because the last
byte is used for zero-termination (so we now always read blocks of exactly 32kb from disk) * set the first byte of the buffer to #0 when opening a file initially git-svn-id: trunk@13576 -
This commit is contained in:
parent
f2691c4ebf
commit
8dbc728926
@ -29,7 +29,7 @@ interface
|
|||||||
cutils,cclasses;
|
cutils,cclasses;
|
||||||
|
|
||||||
const
|
const
|
||||||
InputFileBufSize=32*1024;
|
InputFileBufSize=32*1024+1;
|
||||||
linebufincrease=512;
|
linebufincrease=512;
|
||||||
|
|
||||||
type
|
type
|
||||||
@ -268,6 +268,7 @@ uses
|
|||||||
endoffile:=false;
|
endoffile:=false;
|
||||||
closed:=false;
|
closed:=false;
|
||||||
Getmem(buf,MaxBufsize);
|
Getmem(buf,MaxBufsize);
|
||||||
|
buf[0]:=#0;
|
||||||
bufstart:=0;
|
bufstart:=0;
|
||||||
bufsize:=0;
|
bufsize:=0;
|
||||||
open:=true;
|
open:=true;
|
||||||
|
Loading…
Reference in New Issue
Block a user