From 883c73c9ff627adff6032baa62e4af13d4416efd Mon Sep 17 00:00:00 2001 From: Shish Date: Sat, 24 Dec 2011 21:51:48 +0000 Subject: [PATCH] even if xdebug is installed, only run coverage when told to --- core/util.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/util.inc.php b/core/util.inc.php index 32523ac4..545b6b8d 100644 --- a/core/util.inc.php +++ b/core/util.inc.php @@ -1031,14 +1031,14 @@ function _end_cache() { \* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ function _start_coverage() { - if(function_exists("xdebug_start_code_coverage")) { + if(COVERAGE && function_exists("xdebug_start_code_coverage")) { #xdebug_start_code_coverage(XDEBUG_CC_UNUSED|XDEBUG_CC_DEAD_CODE); xdebug_start_code_coverage(XDEBUG_CC_UNUSED); } } function _end_coverage() { - if(function_exists("xdebug_get_code_coverage")) { + if(COVERAGE && function_exists("xdebug_get_code_coverage")) { if(!file_exists("data/coverage")) mkdir("data/coverage"); $n = 0; $t = time();