X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=src%2Flogger.pl;h=8309a14fa3f6817fb589eebc0c10472debcd88e9;hb=d337f15b80c305f20994c630ac788b337cf2ab60;hp=5a8fd1a893c3db31de7e3053a4f9ecddfb531bea;hpb=41977257defbd07a53f3f87f4c187a2f661b0924;p=infobot.git diff --git a/src/logger.pl b/src/logger.pl index 5a8fd1a..8309a14 100644 --- a/src/logger.pl +++ b/src/logger.pl @@ -97,7 +97,7 @@ sub openLog { } if (open(LOG, ">>$file{log}")) { - binmode(LOG, ":utf8"); + binmode(LOG, ":encoding(UTF-8)"); &status("Opened logfile $file{log}."); LOG->autoflush(1); } else { @@ -376,11 +376,11 @@ sub debug_perl { &status("WARN: cannot open $file: $!"); return; } - binmode(IN, ":utf8"); + binmode(IN, ":encoding(UTF-8)"); # TODO: better filename. open(OUT, ">>debug.log"); - binmode(OUT, ":utf8"); + binmode(OUT, ":encoding(UTF-8)"); print OUT "DEBUG: $str\n"; # note: cannot call external functions because SIG{} does not allow us to. @@ -415,7 +415,7 @@ sub openSQLDebug { delete $param{'SQLDebug'}; return 0; } - binmode(SQLDEBUG, ":utf8"); + binmode(SQLDEBUG, ":encoding(UTF-8)"); &status("Opened SQL Debug file: $param{'SQLDebug'}"); return 1;