|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2008-07-11 13:57 UTC] jani@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 19 16:00:01 2025 UTC |
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.