ID: 26286 Comment by: erikp at visibleworld dot com Reported By: igg10 at alu dot ua dot es Status: No Feedback Bug Type: Apache2 related Operating System: Windows 2000 PHP Version: 4.3.4 New Comment:
Problem persists with php 4.3.8 on win2k, apache/2.0.50 and apache/2.0.51. Previous Comments: ------------------------------------------------------------------------ [2004-09-16 14:57:11] dmitri at elista dot org I also ran across this apache crash. The log file record was the same as in the first message. Here is how it happened. I run apache2 with php 4.3.2 under windows 2000. The crash itself occured when I made a request to MSSQL database selecting a field of type DECIMAL(38). As far as I understand it means a number 38 digits long taking 17 bytes to be stored. PHP's manual says "The size of a float is platform-dependent, although a maximum of ~1.8e308 with a precision of roughly 14 decimal digits is a common value (that's 64 bit IEEE format)." So I figured I could try to convert the number into a smaller number. And it helped! I rewrote the SQL request as follows SELECT CONVERT(DECIMAL(15,2), [Decimal38]) FROM ... I don't think cutting the number down is such a big deal as it is extremely seldom that we deal with such bug numbers in the real life. 38 digits or 15 - make no difference :) ------------------------------------------------------------------------ [2004-09-05 20:09:00] nuwp at mail dot com In my case, this happens when I turn off the cookies in Mozilla for the site I am developing. The PHP scripts then use some classes stored in $_SESSION[] during the requests. So if the cookies are not allowed, session does not work, and then the Apache crashes. ------------------------------------------------------------------------ [2004-08-30 23:17:11] ajvdhek at dds dot nl Exact same bug for me... Win XP pro + XAMMP 1.4.6 (Apache/2.0.50 (Win32) mod_ssl/2.0.50 OpenSSL/0.9.7c PHP/5.0.1 MySQL 4.0.20a-nt) ------------------------------------------------------------------------ [2004-07-05 16:23:19] adam dot phillips at orange dot net Continuing from my post above, I tried replacing the switch statement with if () {} elseif ... and still got the error so it appears it is not the switch statement ------------------------------------------------------------------------ [2004-07-05 16:01:24] adam dot phillips at orange dot net I experienced the same problem on 2 systems - Win2k with Apache 2.0.48/PHP 4.3.4 and Red Hat Linux with Apache 1.3.29 and PHP 4.3.5. So far as i can tell, the cause of the error is a switch statement. I have a function withian a class module declared as follows: function getsales($scope="", $returnasobjects=false) { } Inside this function is a switch statment based on $scope. There are four cases. The first three perform different functions which all return arrays and the fourth case (which is the default) performs all 3 of the previous cases and merges the results into a single array (I won't write out all the code since it all appears to work outside of this switch statement. Please e-mail if needed). The error occurs in the fourth case but originally the code was identical to that of the first 3 'stuck together'. I have since tried a number of alternatives none of which work. Most intriguing was when instead of using default: for the fourth case i renamed it case "all". Then it worked when called from another page but not when called from within the same class module. I then renamed it "everything" and the opposite was true. I then tried changed my function declaration to function getsales($scope="all", $returnasobjects=false) {} and it wouldn't work in either case. Similarly if i replaced "all" with everything. The final bit of strangeness was that i tried using the following code in the default case return array_merge($this->getsales("case1"), $this->getsales("case2"), $this->getsales("case3")) which wouldn't work even tho each of the cases worked individually. Each time i get the same error in my Apache Error Log Parent: child process exited with status 3221225725 -- Restarting ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/26286 -- Edit this bug report at http://bugs.php.net/?id=26286&edit=1