#18743 [Opn->Fbk]: Pushing values to an array dies with large number of elements
| From: | sander@php.net | Date: | Mon, 05 Aug 2002 18:32:52 +0000 |
| Subject: | #18743 [Opn->Fbk]: Pushing values to an array dies with large number of elements | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-16016@lists.php.net to get a copy of this message | ||
ID: 18743
Updated by: sander@php.net
Reported By: mgrommet@yahoo.com
-Status: Open
+Status: Feedback
Bug Type: Reproducible crash
Operating System: Linux Redhat 7.2
PHP Version: 4.2.2
New Comment:
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php
Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2002-08-05 13:59:03] mgrommet@yahoo.com
I have an object with a method that performs a mysql search.
It collects values from the search results, and pushes them on to an
array to return.
This code works great for smaller query results, but it causes a
segmentation fault with larger numbers (approximately 1300 results)
Running PHP 4.2.2
Apache 1.3.6 (mod_frontpage, mod_rewrite)
MySQL 3.23.43
--- EXAMPLE CODE ---
$mailDbLink = mysql_connect($mailserver,$mailuser,$mailpass) or
die("Could not connect to mail system");
mysql_select_db($maildbname) or die("Could not select appropriate
database in 98-11 system");
$query = mysql_query($processEmailTableSql) or die("Could not
perform 98-11 search: " . mysql_error());
while($row = mysql_fetch_array($query))
{
array_push($resultsArray,$row["MessageID"]);
}
return $resultsArray;
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=18743&edit=1