mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 20:00:37 +02:00
Support cpu-usage rendertime
This commit is contained in:
11
class2.php
11
class2.php
@@ -1,4 +1,4 @@
|
||||
<?php
|
||||
<?php
|
||||
/*
|
||||
+ ----------------------------------------------------------------------------+
|
||||
| e107 website system
|
||||
@@ -11,9 +11,9 @@
|
||||
| GNU General Public License (http://gnu.org).
|
||||
|
|
||||
| $Source: /cvs_backup/e107_0.8/class2.php,v $
|
||||
| $Revision: 1.15 $
|
||||
| $Date: 2007-02-12 20:04:46 $
|
||||
| $Author: e107steved $
|
||||
| $Revision: 1.16 $
|
||||
| $Date: 2007-03-04 21:47:15 $
|
||||
| $Author: mrpete $
|
||||
+----------------------------------------------------------------------------+
|
||||
*/
|
||||
//
|
||||
@@ -43,6 +43,7 @@
|
||||
// A: Honest global beginning point for processing time
|
||||
//
|
||||
$eTimingStart = microtime(); // preserve these when destroying globals in step C
|
||||
if ( function_exists( 'getrusage' ) ) { $eTimingStartCPU = getrusage(); }
|
||||
$oblev_before_start = ob_get_level();
|
||||
|
||||
//
|
||||
@@ -64,7 +65,7 @@ if(function_exists('ini_get')) {
|
||||
// Destroy! (if we need to)
|
||||
if($register_globals == true){
|
||||
while (list($global) = each($GLOBALS)) {
|
||||
if (!preg_match('/^(_POST|_GET|_COOKIE|_SERVER|_FILES|GLOBALS|HTTP.*|_REQUEST|retrieve_prefs|eplug_admin|eTimingStart)|oblev_.*$/', $global)) {
|
||||
if (!preg_match('/^(_POST|_GET|_COOKIE|_SERVER|_FILES|_SESSION|GLOBALS|HTTP.*|_REQUEST|retrieve_prefs|eplug_admin|eTimingStart.*|oblev_.*)$/', $global)) {
|
||||
unset($$global);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user