|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-06-08 09:57 UTC] derick@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 08 06:00:01 2025 UTC |
Description: ------------ In WinXP, crash occurs at $howmany >= 65537; in Mandrake Linux, crash (specifying Segmentation fault) occurs at $howmany >= 131073. Note that crash only occurs *after* all statements are performed. I have been able to reproduce this everywhere, with any 4.3.2+ version of PHP on all platforms, regardless of configuration or state of php.ini. Reproduce code: --------------- <?php $string = "X"; $howmany = 65537; $b4guts = mktime(); $guts = array(); for ( $x = 0; $x < $howmany; $x++ ) { $guts[$x] = $string; } $afterguts = mktime(); $gutstime = $afterguts - $b4guts; echo "\nGuts built. Time $gutstime seconds. ", count($guts), " elements\n"; ?> Expected result: ---------------- Normal program termination. Actual result: -------------- Windows generates a GPF requiring close of the process. Mandrake Linux generates a "Segmentation fault".