Re: PHP 4.0 Bug #5781 Updated: scrambled values and segmentation fault after getenv and mssql_*

From: Date: Wed, 04 Oct 2000 12:17:08 +0000
Subject: Re: PHP 4.0 Bug #5781 Updated: scrambled values and segmentation fault after getenv and mssql_*
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-34225@lists.php.net to get a copy of this message
Hi All! Sorry, I can't say anything about this failure, because I'm currently not at this project. I have changed the firm and I didn't know, who will work on it (at this moment, I have the suspicion there are nobody work on the project). Sorry, that I can't say more about it. Ciao Markus PS: Mark McCorkle [mccorkle@surfsouth.com] wrote an answer to me. - Mail of Mark -Subject:[pertaining to your bug report with php4]---- I've not a CVS user, so I can't post a comment there, but here's my $.02 worth. I'm getting the same type thing when I run a mssql query through my 4.0.1pl2 of php (cgi version). I used gdb and watched it segfault and it's doing so because of zend trying to clean up memory -- I thought for a minute and I think I've got our answer. MSSQL 7.0 (possibly earlier) using the TDS 7.0 format does not always end it's strings like it should. Meaning: $array = mssql_fetch_array ( $result ); $custname_rname[$i] = $array[0]; $custrate_rgid[$i] = $array[1]; and then running through the array of ints (custrate_rgid) I get a segfault. If I instead force custrate_rgid[$i] to be a charecter by doing this: $custrate_rgid[$i] = $array[1].""; No more segfault :-) Hope that helps. I'm gonna try to send this to someone at php and at freetds (the linux package I use in place of Sybase) and see if they can fix it to help us avoid this workaround. --mark mccorkle Deal with the faults of others as gently as with your own. ancient Chinese proverb - End Mail -------------------------------------------------------------------- >ID: 5781 >Updated by: sniper >Reported By: markus@htu.at >Status: Closed >Bug Type: *General Issues >Assigned To: >Comments: > >No feedback. > >--Jani > >Previous Comments: >--------------------------------------------------------------------------- > >[2000-09-04 20:17:10] sniper@php.net >Does this problem still exist with php4.0.2 ? >And if it does, please include a gdb backtrace. > >--Jani > >--------------------------------------------------------------------------- > >[2000-07-25 18:45:08] markus@htu.at >In some cases >- the page could not be loaded or >- getenv("REMOTE_ADDR") have crazy values >- or some values of mssql_fetch_row delivers scrambled values. > >When the scrambled values are visible I get this entry in the https_error.log >Tue Jul 25 18:32:38 2000] [notice] child pid 16557 exit signal Segmentation fault (11) > >You can see this behaviour on >http://www.wisur.at/wisur/test1.php >There are also a screenshot and a link to the source code >of the script. >To get information of my PHP-installation please visit >http://www.wisur.at/wisur/info.php > >TNX for your work >Markus > >--------------------------------------------------------------------------- > > >Full Bug description available at: http://bugs.php.net/?id=5781 > >

« previous php.dev (#34225) next »