tweaks:
authorAlexandre Emsenhuber <ialex@users.mediawiki.org>
Tue, 29 Apr 2008 16:35:11 +0000 (16:35 +0000)
committerAlexandre Emsenhuber <ialex@users.mediawiki.org>
Tue, 29 Apr 2008 16:35:11 +0000 (16:35 +0000)
* group master queries with other queries in "SQL Queries" in profileinfo.php
* end 'main-misc-setup' section before executing ajax requests so that they don't get closed by the profiler for ajax requests.

index.php
profileinfo.php

index d5a42a3..4bbf98f 100644 (file)
--- a/index.php
+++ b/index.php
@@ -61,6 +61,8 @@ if ($wgTitle == NULL) {
        unset( $wgTitle );
 }
 
+wfProfileOut( 'main-misc-setup' );
+
 #
 # Send Ajax requests to the Ajax dispatcher.
 #
@@ -73,8 +75,6 @@ if ( $wgUseAjax && $action == 'ajax' ) {
        exit;
 }
 
-wfProfileOut( 'main-misc-setup' );
-
 # Setting global variables in mediaWiki
 $mediaWiki->setVal( 'action', $action );
 $mediaWiki->setVal( 'CommandLineMode', $wgCommandLineMode );
index ab28785..5ea37c0 100644 (file)
@@ -283,7 +283,7 @@ while (($o = mysql_fetch_object($res)) !== false) {
                }
        }
        $last = $next;
-       if (preg_match("/^query: /", $next->name())) {
+       if (preg_match("/^query: /", $next->name()) || preg_match("/^query-m: /", $next->name())) {
                $sqltotal += $next->time();
                $queries[] = $next;
        } else {