ID: 21481 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Bogus +Status: Open Bug Type: MSSQL related Operating System: windows 2000/sp3 PHP Version: 4CVS-2003-01-07 (stable) New Comment:
Sorry, this is my mistype. in my test script all was fine. and, also, I reopen this bug report. When 25 connections was reached, no new connection will open. Then I change option "allow persistant" to Off in php.ini. All working fine. I assume this is not a bogus, this is a bug. Previous Comments: ------------------------------------------------------------------------ [2003-01-07 05:48:56] [EMAIL PROTECTED] A little comment to let [EMAIL PROTECTED] knows that his script is bogus: <? $db=mssql_connect("server","user","pass"); mssql_close("db"); ?> should be <? $db=mssql_connect("server","user","pass"); mssql_close($db); ?> Thank you for your report. ------------------------------------------------------------------------ [2003-01-07 05:43:01] [EMAIL PROTECTED] In the db extensions connections will be closed via destructor functions, which will be called when zend_list_delete is executed: see: PHP_MINIT_FUNCTION and _close_[extname]_link ------------------------------------------------------------------------ [2003-01-07 04:07:18] [EMAIL PROTECTED] And also: If I create file like this: <? $db=mssql_connect("server","user","pass"); mssql_close("db"); ?> and run it a lot of times, after 25 times I got message "unable connect to server" from mssql_connect when I go to mssql entreprise manager I will see 25 connections from PHP. If I restart apache all connections will be closed. PS: I use apache 1.3.27/w32 Same behavior with all databases, as I understand, there is another childs logic instead unix. Waiting for comments ------------------------------------------------------------------------ [2003-01-07 02:06:41] [EMAIL PROTECTED] Hello! I call mssql_close function for close connection but, as I see in php_mssql.c file this function do nothing (ie don't really closes connection) see code: ZEND_FETCH_RESOURCE2(mssql_ptr, mssql_link *, mssql_link_index, id, "MS SQL-Link", le_link, le_plink); if (mssql_link_index) zend_list_delete(Z_LVAL_PP(mssql_link_index)); else zend_list_delete(id); RETURN_TRUE; where is dbclose and dbfreelogin staments? vladimir Novosibirsk, Russia ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=21481&edit=1