forked from github/kensanata.oddmuse
No longer validate the UTF-8 from rc.log files in GetRcLinesFor.
If the rc.log file contained invalid UTF-8, this would fill the server logs with thousands of warnings. There is nothing we can do about these (they probably originated from an older copy of the script). Therefore, <:utf8 is now used instead of <:encoding(UTF-8).
This commit is contained in:
3
wiki.pl
3
wiki.pl
@@ -1586,7 +1586,8 @@ sub GetRcLinesFor {
|
||||
rcclusteronly rcfilteronly match lang followup);
|
||||
# parsing and filtering
|
||||
my @result = ();
|
||||
open(F, '<:encoding(UTF-8)', $file) or return ();
|
||||
# using :utf8 instead of :encoding(utf-8) to avoid validation and warnings on corrupt files :(
|
||||
open(F, '<:utf8', $file) or return ();
|
||||
while (my $line = <F>) {
|
||||
chomp($line);
|
||||
my ($ts, $id, $minor, $summary, $host, $username, $revision,
|
||||
|
||||
Reference in New Issue
Block a user