From 51e9917aa8c38f464d57b2bd72a8e159eb7668ff Mon Sep 17 00:00:00 2001 From: Tim Starling Date: Wed, 16 Sep 2009 03:48:29 +0000 Subject: [PATCH] Fix for bug 20601: disable debug output. It can be re-enabled by patching. --- includes/diff/DifferenceEngine.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/includes/diff/DifferenceEngine.php b/includes/diff/DifferenceEngine.php index e49a860fc3..8e6d2a952c 100644 --- a/includes/diff/DifferenceEngine.php +++ b/includes/diff/DifferenceEngine.php @@ -30,6 +30,13 @@ class DifferenceEngine { var $mCacheHit = false; // Was the diff fetched from cache? var $htmldiff; + /** + * Set this to true to add debug info to the HTML output. + * Warning: this may cause RSS readers to spuriously mark articles as "new" + * (bug 20601) + */ + var $enableDebugComment = false; + // If true, line X is not displayed when X is 1, for example to increase // readability and conserve space with many small diffs. protected $mReducedLineNumbers = false; @@ -827,6 +834,9 @@ CONTROL; */ protected function debug( $generator="internal" ) { global $wgShowHostnames; + if ( !$this->enableDebugComment ) { + return ''; + } $data = array( $generator ); if( $wgShowHostnames ) { $data[] = wfHostname(); -- 2.20.1