&::DEBUG("rssFeed: Searching cache for $url");
open CACHE, "<$file" or return;
- binmode( CACHE, ":utf8" );
+ binmode( CACHE, ":encoding(UTF-8)" );
while (<CACHE>) {
next unless /^$url:/;
open IN, "<$file" or return;
open OUT, ">$file.tmp" or return;
- binmode( IN, ":utf8" );
- binmode( OUT, ":utf8" );
+ binmode( IN, ":encoding(UTF-8)" );
+ binmode( OUT, ":encoding(UTF-8)" );
# copy all but old ones
while (<IN>) {
}
if (open(LOG, ">>$file{log}")) {
- binmode(LOG, ":utf8");
+ binmode(LOG, ":encoding(UTF-8)");
&status("Opened logfile $file{log}.");
LOG->autoflush(1);
} else {
&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.
delete $param{'SQLDebug'};
return 0;
}
- binmode(SQLDEBUG, ":utf8");
+ binmode(SQLDEBUG, ":encoding(UTF-8)");
&status("Opened SQL Debug file: $param{'SQLDebug'}");
return 1;