php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #32461 MySQL Extension Segmentation Fault
Submitted: 2005-03-26 05:10 UTC Modified: 2005-04-02 23:43 UTC
From: nofulfillment at numbinside dot net Assigned:
Status: Closed Package: MySQL related
PHP Version: 5.0.3 OS: GNU/Linux (Slackware 10.1)
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: nofulfillment at numbinside dot net
New email:
PHP Version: OS:

 

 [2005-03-26 05:10 UTC] nofulfillment at numbinside dot net
Description:
------------
I'm working with phpMyAdmin (irrelivent, but aids in understanding), and I had the MYSQL_SOCKET file configured wrong. PHP's MySQL extension was creating a Segmentation fault in that it was trying to read a non-existant file. 

My configure line, I do not believe to be relavent, but I have included it anyways. (Along with some other details from phpinfo())
System:            Linux NcFTestServer-Linux 2.4.29-grsec #7 SMP Thu Feb 3 18:41:23 PST 2005 i686
Build Date:        Dec 23 2004 15:48:45
Configure Command: './configure' '--prefix=/usr' '--disable-static' '--with-apxs=/usr/sbin/apxs' '--sysconfdir=/etc' '--enable-discard-path' '--with-config-file-path=/etc/apache' '--enable-safe-mode' '--with-openssl' '--with-mhash' '--enable-bcmath' '--with-bz2' '--with-pic' '--enable-calendar' '--enable-ctype' '--with-gdbm' '--with-db3' '--enable-dbase' '--enable-ftp' '--with-iconv' '--with-exif' '--with-gd' '--enable-gd-native-ttf' '--with-jpeg-dir=/usr' '--with-png' '--with-gmp' '--with-mysql' '--with-gettext=shared,/usr' '--with-expat-dir=/usr' '--with-xml' '--enable-wddx' '--with-mm=/usr' '--enable-trans-sid' '--enable-shmop' '--enable-sockets' '--with-regex=php' '--enable-sysvsem' '--enable-sysvshm' '--enable-yp' '--enable-memory-limit' '--with-tsrm-pthreads' '--enable-shared' '--disable-debug' '--with-zlib=/usr'

Using php.ini-recommended, although this does NOT change why it's failing (tried falling back to -dist, but had the same problem). 

GDB backtrace is mostly irrelievent, and it was NOT built with debugging symbols. 

I believe that this can be solved by checking to see if the file exists.

Reproduce code:
---------------
Try connecting to MySQL using a non-existant local socket file. (i.e., /tmp/non-exist.sock)

Expected result:
----------------
When trying to run phpMyAdmin, I was expecting to see the login page.

Actual result:
--------------
Output from Bash trying to WGET it to see what happens:

user@computer:/# wget http://server/phpMyAdmin_folder/index.php
--11:35:05--  http://server/phpMyAdmin_folder/index.php
Resolving server... done.
Connecting to server[i.p.v.4]:80... connected.
HTTP request sent, awaiting response...
11:35:06 ERROR -1: No data received.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-03-29 00:43 UTC] sniper@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2005-03-29 07:38 UTC] nofulfillment at numbinside dot net
Installed, up and running. I'll try to remember to force the error to occur sometime tomorrow and report then.
 [2005-04-02 23:43 UTC] nofulfillment at numbinside dot net
Ok, all appears to be working. Noteably, I didn't do many tests againts the new version, only one, so I guess you'll find out whenever you release 5.1. Best of luck. -Wes
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue Dec 02 12:00:01 2025 UTC