From: ripper at ripper dot net dot ar
Operating system: Linux / Windows
PHP version: 5.1.5
PHP Bug Type: Performance problem
Bug description: File over size
Description:
------------
A php script with a sockets fuction or fopen or maybe a ftp functions may
cause a download file wich cause in some cases a crash of apache, or a
over size file > 1gb inside the hd.
Reproduce code:
---------------
<?
set_time_limit(0);
$fp = fopen ("testfile.woext","w");
for ($a = 0; $a < 65535; $a++)
for ($b = 0; $b < 65535; $b++)
for ($c = 0; $c < 65535; $c++)
{
$str = "File OverSize!!!!";
fputs($fp,$str,strlen($str);
}
fclose($fp);
?>
Expected result:
----------------
A message with WARNING or something setted by php config
Actual result:
--------------
A file size > 1gb or maybe 2gb
--
Edit bug report at http://bugs.php.net/?id=38513&edit=1
--
Try a CVS snapshot (PHP 4.4):
http://bugs.php.net/fix.php?id=38513&r=trysnapshot44
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=38513&r=trysnapshot52
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=38513&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=38513&r=fixedcvs
Fixed in release:
http://bugs.php.net/fix.php?id=38513&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=38513&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=38513&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=38513&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=38513&r=support
Expected behavior: http://bugs.php.net/fix.php?id=38513&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=38513&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=38513&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=38513&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38513&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=38513&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=38513&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=38513&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=38513&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=38513&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=38513&r=mysqlcfg