aboutsummaryrefslogtreecommitdiffstats
path: root/includes/HTMLFileCache.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/HTMLFileCache.php')
-rw-r--r--includes/HTMLFileCache.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/includes/HTMLFileCache.php b/includes/HTMLFileCache.php
index e267962c58db..ce4c11a57adb 100644
--- a/includes/HTMLFileCache.php
+++ b/includes/HTMLFileCache.php
@@ -165,7 +165,10 @@ class HTMLFileCache {
return $origtext; // return to output
}
$text = $origtext;
+ // Empty?
if( strcmp($text,'') == 0 ) return '';
+ // Probably broken? (OOM and PHP errors)
+ if( mb_strlen($text) < 512 ) return $origtext;
wfDebug(" saveToFileCache()\n", false);