php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #45481 the function PHP_MSHUTDOWN_FUNCTION was called by every process of apache but
Submitted: 2008-07-11 07:59 UTC Modified: 2008-07-11 13:57 UTC
From: xufei_ok at 126 dot com Assigned:
Status: Not a bug Package: Apache2 related
PHP Version: 5.2.6 OS: redhat linux 2.6.18-8.el5
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: xufei_ok at 126 dot com
New email:
PHP Version: OS:

 

 [2008-07-11 07:59 UTC] xufei_ok at 126 dot com
Description:
------------
In the php extension moduld the function PHP_MSHUTDOWN_FUNCTION was called by every process of apache while PHP_MINIT_FUNCTION only was called one time by the parent process of apache.

It cause the whold module only was  initialized one times but was finalized several times.

Reproduce code:
---------------
PHP_MINIT_FUNCTION(zraidapi)
{
	/* If you have INI entries, uncomment these lines 
	REGISTER_INI_ENTRIES();
	*/
	ZA_DBG_Init( "" );
      if( FALSE == zRaidApiInit() ) // 0 - SILENT_MODE, 1 - BUZZER_MODE
      {
	       zend_error( E_ERROR, "zRaidApiInit() failed!!" );
	       return FAILURE;
      }
      STORE_KEY(PHP_ZRAIDAPI, 1, 0, 0, 18);
	return SUCCESS;
}

PHP_MSHUTDOWN_FUNCTION(zraidapi)
{
	/* uncomment this line if you have INI entries
	UNREGISTER_INI_ENTRIES();
	*/
    	zRaidApiShutdown();
    	ZA_DBG_Shutdown();
	return SUCCESS;
}

Expected result:
----------------
I want to get some explaination about when the PHP_MINIT_FUNCTION and PHP_MSHUTDOWN_FUNCTION were called , and whether it is a bug of php or apache2. 


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-07-11 13:57 UTC] jani@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

Ask such questions on the mailing lists. For example internals@lists.php.net 
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu May 16 13:01:32 2024 UTC