I want to use fread()
for IO for some reason (speed and ...). i have a file with different sized lines. by using a code like:
while( !EOF ){
fread(buffer,500MB,1,fileName);
// process buffer
}
the last line may read incompletely and we have to read the last line again in next trial, so how to force fread()
to continue from the beginning of the last line?
or if possible how to force fread()
to read more than 500MB untill reaching a \n or another specific character?
Thanks All
Ameer.