php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #47447 http crash
Submitted: 2009-02-19 09:59 UTC Modified: 2009-02-22 09:48 UTC
From: sife_php at yahoo dot com Assigned:
Status: Not a bug Package: MySQL related
PHP Version: 5.2CVS-2009-02-19 (CVS) OS: Win XP SP2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: sife_php at yahoo dot com
New email:
PHP Version: OS:

 

 [2009-02-19 09:59 UTC] sife_php at yahoo dot com
Description:
------------
package has been used : 
mysql-noinstall-5.1.30
httpd-2.2.11x86ssl
php-5.2.8

when try to connect to mysql server via php the apache is crash .
NOTE : i had use httpd 2.2.8 with php 5.2.8 and mysql 5.0.51b communty with no problem .


Reproduce code:
---------------
<?php
class MySQL
 {
   private $hDB;  
     function __construct($host,$user,$pass,$db)
      {
        $this->hDB=mysql_connect($host,$user,$pass);
        if(!$this->hDB && mysql_select_db($db,$this->hDB))
         echo "error";
        else
         return $this->hDB;
      }
     function __destruct()
      {
       mysql_close($this->hDB);
      } 
 }
$test=new MySQL("127.0.1","root","00000","mysql");
?>

Expected result:
----------------
a MSG that is say : don't send (http crash with out stop)


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-02-19 10:06 UTC] pajoye@php.net
Do you use mysql 5.1?
 [2009-02-22 06:42 UTC] sife_php at yahoo dot com
yes .
 [2009-02-22 09:48 UTC] pajoye@php.net
Do not use libmysql 5.1 with PHP. Be sure that the libmysql delivered with PHP is used (c:\php must be first in your path).

Check the other reports about this issue for a more detailed explanation.

Not a php bug > bogus.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun May 05 07:01:32 2024 UTC