aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki.pm
diff options
context:
space:
mode:
authorSimon McVittie <smcv@debian.org>2016-01-21 07:25:25 +0000
committerSimon McVittie <smcv@debian.org>2016-01-21 07:33:41 +0000
commitb8dbb48fdce9ffc00d1f3f4267948ee2875d2970 (patch)
tree52851586913097cfd80f4b2a7f169cf695f408b9 /IkiWiki.pm
parenta8951de19eff73dc3d2e1d1b20518ecb56133184 (diff)
downloadikiwiki-b8dbb48fdce9ffc00d1f3f4267948ee2875d2970.tar
ikiwiki-b8dbb48fdce9ffc00d1f3f4267948ee2875d2970.tar.gz
Force log messages to be bytestrings
Sys::Syslog is not UTF-8-literate.
Diffstat (limited to 'IkiWiki.pm')
-rw-r--r--IkiWiki.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm
index fe5af6d15..97fe6b8ff 100644
--- a/IkiWiki.pm
+++ b/IkiWiki.pm
@@ -846,7 +846,9 @@ sub log_message ($$) {
# keep a copy to avoid editing the original config repeatedly
my $wikiname = $config{wikiname};
utf8::encode($wikiname);
- Sys::Syslog::syslog($type, "[$wikiname] %s", join(" ", @_));
+ my $message = join(" ", @_);
+ utf8::encode($message);
+ Sys::Syslog::syslog($type, "[$wikiname] %s", $message);
};
if ($@) {
print STDERR "failed to syslog: $@" unless $log_failed;