PHP (Cli) generates invalid output when it exceeds 4kB
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
php5 (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: php5-cli
I've written small script for generate sql query:
--------
echo "INSERT INTO prices (category_from_id, category_to_id, fee) VALUES ";
for($i = 1; $i <= 18; $i++){
for($j = 1; $j <= 18; $j++){
$fee = rand(1, 100);
echo "($i, $j, $fee), ";
}
}
echo "\n";
--------
and when output exceeds 4kB, it generates invalid output (lost few characters):
--------
(18, 5, 83), (18, 6, 71), (1(18, 8, 48),
--------
(1(18... instead (18, 7, 12), (18...
I've output buffering turned off (as can see in attached php.ini file). On native php 5.2.6 everything works OK (checked on another machine)
My system (Kubunt) version details:
$ lsb_release -rd
Description: Ubuntu 8.04.1
Release: 8.04
$ php --version
PHP 5.2.4-2ubuntu5.3 with Suhosin-Patch 0.9.6.2 (cli) (built: Jul 23 2008 06:44:49)
Copyright (c) 1997-2007 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies
Changed in php5: | |
status: | New → Incomplete |
I can't reproduce this;
mr-russ@bob:~$ php --version
PHP 5.2.4-2ubuntu5.3 with Suhosin-Patch 0.9.6.2 (cli) (built: Jul 23 2008 06:46:18)
Copyright (c) 1997-2007 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies
I've tried with both mcrypt extension installed and without. Neither produces the error for me. What php extensions do you have installed. I can only think something is going on there. Are you on 64 bit or 32 bit?
I've tried on both amd64 and 32bit. Neither produces the error.
The only other strange thing is that my build is 2 minutes later than yours for php. Is something funny going on there. Can you force a reinstall of php and see if the bug continues?