php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #30429 crash on executing mysql_create_db
Submitted: 2004-10-14 07:38 UTC Modified: 2004-10-17 13:11 UTC
From: casualprogrammer at yahoo dot com Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 5.0.2 OS: Windows XP, SP2
Private report: No CVE-ID: None
 [2004-10-14 07:38 UTC] casualprogrammer at yahoo dot com
Description:
------------
When executing the example for mysql_create_db from the php manual, mysql (4.1g) will crash with an access violation.

The browser reports :

Notice: mysql_create_db() [function.mysql-create-db]: This function is deprecated, please use mysql_query() to issue a SQL CREATE DATABASE statement instead. in C:\WUTemp\Adventure\advphp1\mysql.php on line 5

Fatal error: Maximum execution time of 30 seconds exceeded in C:\WUTemp\Adventure\advphp1\mysql.php on line 5

After restarting mySQL it reports, that the new database is existent.

The configuration is : Windows XP, SP2, IIS 5.1, PHP 5.02 ISAPI, mySQL 4.1G


Reproduce code:
---------------
<?php 
   $link = mysql_pconnect("localhost", "mysql_user", "mysql_password") 
       or die("Could not connect: " . mysql_error()); 

   if (mysql_create_db("my_db")) { 
       print ("Database created successfully\n"); 
   } else { 
       printf ("Error creating database: %s\n", mysql_error()); 
   } 
?>


Expected result:
----------------
Correct creation of a new database.

Actual result:
--------------
Ereignistyp:	Fehler
Ereignisquelle:	Application Error
Ereigniskategorie:	(100)
Ereigniskennung:	1000
Datum:		14.10.2004
Zeit:		07:25:00
Benutzer:		Nicht zutreffend
Computer:	WORKSTATION1
Beschreibung:
Fehlgeschlagene Anwendung mysqld-nt.exe, Version 0.0.0.0, fehlgeschlagenes Modul mysqld-nt.exe, Version 0.0.0.0, Fehleradresse 0x00081ba0.

Weitere Informationen ?ber die Hilfe- und Supportdienste erhalten Sie unter http://go.microsoft.com/fwlink/events.asp.
Daten:
0000: 41 70 70 6c 69 63 61 74   Applicat
0008: 69 6f 6e 20 46 61 69 6c   ion Fail
0010: 75 72 65 20 20 6d 79 73   ure  mys
0018: 71 6c 64 2d 6e 74 2e 65   qld-nt.e
0020: 78 65 20 30 2e 30 2e 30   xe 0.0.0
0028: 2e 30 20 69 6e 20 6d 79   .0 in my
0030: 73 71 6c 64 2d 6e 74 2e   sqld-nt.
0038: 65 78 65 20 30 2e 30 2e   exe 0.0.
0040: 30 2e 30 20 61 74 20 6f   0.0 at o
0048: 66 66 73 65 74 20 30 30   ffset 00
0050: 30 38 31 62 61 30         081ba0  


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-10-14 09:20 UTC] georg@php.net
Which client library version do you use 
(mysql_get_client_info or phpinfo output) ? 
 [2004-10-14 09:58 UTC] casualprogrammer at yahoo dot com
Hallo Georg,

I have no idea, how can I find that out ?

Casual
 [2004-10-14 15:45 UTC] casualprogrammer at yahho dot com
Hi Georg,

obviously I didn't realize, that you already mentioned how to get at that info :-(

the php info mentions under mySQL:

Client API version  3.23.57  

Sorry for goofing, Casual
 [2004-10-17 12:34 UTC] casualprogrammer at yahho dot com
This is taken care of by mySQL AB

Casual

ATTENTION! Do NOT reply to this email!
To reply, use the web interface found at http://bugs.mysql.com/?id=6081&edit=2


 ID:               6081
 Updated by:       Dmitri Lenev
 Reported by:      Casual Programmer
 User Type:        User
-Status:           Verified
+Status:           Patch pending
 Priority:         Medium
 Severity:         Serious
 Category:         Server
 Operating System: windows xp, sp2/Linux
 Version:          4.1g
 Assigned To:      dlenev at mysql dot com
 New Comment:

ChangeSet
  1.2107 04/10/17 13:59:46 dlenev at brandersnatch dot localdomain +2 -0
  Fix for bug #6081 "Call to deprecated mysql_create_db() function crashes
  server".
 [2004-10-17 13:11 UTC] derick@php.net
Marking it as bogus then, as it was not a bug in PHP.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jun 03 08:01:30 2024 UTC