#24181 [Opn->Csd]: mysql_info() causes segfault
| From: | iliaa@php.net | Date: | Mon, 16 Jun 2003 18:12:25 +0000 |
| Subject: | #24181 [Opn->Csd]: mysql_info() causes segfault | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-42066@lists.php.net to get a copy of this message | ||
ID: 24181
Updated by: iliaa@php.net
Reported By: tmiller at web-1hosting dot net
-Status: Open
+Status: Closed
Bug Type: MySQL related
Operating System: Linux-2.4.20
PHP Version: 4.3.2
New Comment:
This bug has been fixed in CVS.
In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.
In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
Thank you for the report, and for helping us make PHP better.
bug fixed -> status closed
Previous Comments:
------------------------------------------------------------------------
[2003-06-16 13:06:56] tmiller at web-1hosting dot net
The CVS snapshot works great with your configure line and my old
configuration.
I must note, however, that I had to change the mysql extension to _not_
be shared in order for it to work. When I compiled it shared, as it
was in my original configure script, it fails to load even with
extension=mysql.so in my php.ini.
No segfaults now though, thank you for taking a look at my problem!
------------------------------------------------------------------------
[2003-06-14 12:57:21] sniper@php.net
Please try using this CVS snapshot:
http://snaps.php.net/php4-STABLE-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-STABLE-latest.zip
I can't reproduce this with the latest CVS..so please try it out.
Also, try it with this configure line instead of yours:
# ./configure --disable-all --disable-cgi --with-mysql=/usr
------------------------------------------------------------------------
[2003-06-14 11:49:55] tmiller at web-1hosting dot net
Php configuration:
http://php.web-1hosting.net/bugs/config.nice
php.ini:
http://php.web-1hosting.net/bugs/php.ini
Anything else I can provide?
------------------------------------------------------------------------
[2003-06-14 05:17:44] sniper@php.net
Does not crash for me. How did you configure PHP?
------------------------------------------------------------------------
[2003-06-13 16:56:33] tmiller at web-1hosting dot net
Description:
------------
When using mysql_info() whithin a class if the link identifier is
passed using $this->connection_id php will crash. This happens both
with apache module and using CLI.
Reproduce code:
---------------
Code may be found at:
http://php.web-1hosting.net/bugs/mysql_info_crash.html
Expected result:
----------------
I expect to see the string "here: Rows matched: 1 Changed: 0 Warnings:
0" on the screen/webpage.
Actual result:
--------------
tmiller@something:~/Developement/htdocs$ ./mysql.php
Segmentation fault (core dumped)
tmiller@something:~/Developement/htdocs$ gdb /usr/bin/php core
(gdb) bt
#0 0x08152672 in zend_fetch_resource (passed_id=0x4, default_id=-1,
resource_type_name=0x4001dc53 "MySQL-Link",
found_resource_type=0x0,
num_resource_types=2) at
/home/tmiller/Php/php-4.3.2/Zend/zend_list.c:123
#1 0x40019bf9 in zif_mysql_info () from
/usr/lib/php/extensions/mysql.so
#2 0x08159c7a in execute (op_array=0x8232be4)
at /home/tmiller/Php/php-4.3.2/Zend/zend_execute.c:1606
#3 0x08159a1b in execute (op_array=0x822cfe4)
at /home/tmiller/Php/php-4.3.2/Zend/zend_execute.c:1650
#4 0x0814d4fb in zend_execute_scripts (type=8, retval=0x0,
file_count=3)
at /home/tmiller/Php/php-4.3.2/Zend/zend.c:869
#5 0x0812787f in php_execute_script (primary_file=0xbffff820)
at /home/tmiller/Php/php-4.3.2/main/main.c:1671
#6 0x0815e788 in main (argc=3, argv=0xbffff8b4)
at /home/tmiller/Php/php-4.3.2/sapi/cli/php_cli.c:806
#7 0x4033bbb4 in __libc_start_main () from /lib/libc.so.6
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=24181&edit=1