[php] fread() only reads 8192 bytes
by jonaskellens from LinuxQuestions.org on (#5H2M2)
Hello
I have the following code, receiving a continuous tcp stream of data (to analyse).
Code:$socket = fsockopen("127.0.0.1","5038", $errno, $errstr, 5);
$wrets = fread($socket, 9216);
echo "mb_strlen:".mb_strlen($wrets, '8bit')."\n";I notice that mb_strlen is at max 8192, which causes certain data to be "cut off".
I wonder how (and where) I can increase this value of 8192 ?


I have the following code, receiving a continuous tcp stream of data (to analyse).
Code:$socket = fsockopen("127.0.0.1","5038", $errno, $errstr, 5);
$wrets = fread($socket, 9216);
echo "mb_strlen:".mb_strlen($wrets, '8bit')."\n";I notice that mb_strlen is at max 8192, which causes certain data to be "cut off".
I wonder how (and where) I can increase this value of 8192 ?