More profile breakage.
[mediawiki.git] / includes / ProfilerStub.php
blobc41845a4d0af3c1ff6bf0fd18fb741ad632e8017
1 <?php
3 # Stub profiling functions
5 $haveProctitle=function_exists("setproctitle");
6 function wfProfileIn( $fn = '' ) {
7 global $hackwhere, $wgDBname, $haveProctitle;
8 if ($haveProctitle) {
9 $hackwhere[] = $fn;
10 setproctitle($fn . " [$wgDBname]");
13 function wfProfileOut( $fn = '' ) {
14 global $hackwhere, $wgDBname, $haveProctitle;
15 if (!$haveProctitle)
16 return;
17 if (count($hackwhere))
18 array_pop($hackwhere);
19 if (count($hackwhere))
20 setproctitle($hackwhere[count($hackwhere)-1] . " [$wgDBname]");
22 function wfGetProfilingOutput( $s, $e ) {}
23 function wfProfileClose() {}
24 $wgProfiling = false;