dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f9ef83c
)
Strip unprintables from debug log: they can cause font switching on the
author
Brion Vibber
<brion@users.mediawiki.org>
Sun, 15 May 2005 06:09:40 +0000
(06:09 +0000)
committer
Brion Vibber
<brion@users.mediawiki.org>
Sun, 15 May 2005 06:09:40 +0000
(06:09 +0000)
terminal which is annoying.
includes/GlobalFunctions.php
patch
|
blob
|
history
diff --git
a/includes/GlobalFunctions.php
b/includes/GlobalFunctions.php
index
e1e9c2a
..
3f9026a
100644
(file)
--- a/
includes/GlobalFunctions.php
+++ b/
includes/GlobalFunctions.php
@@
-269,6
+269,9
@@
function wfDebug( $text, $logonly = false ) {
$wgOut->debug( $text );
}
if ( '' != $wgDebugLogFile && !$wgProfileOnly ) {
+ # Strip unprintables; they can switch terminal modes when binary data
+ # gets dumped, which is pretty annoying.
+ $text = preg_replace( '![\x00-\x08\x0b\x0c\x0e-\x1f]!', ' ', $text );
@error_log( $text, 3, $wgDebugLogFile );
}
}