summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Friesel <derf@derf.homelinux.org>2010-05-28 11:03:18 +0200
committerDaniel Friesel <derf@derf.homelinux.org>2010-05-28 11:03:18 +0200
commit233001a0e369ae145c571ffdc8789f2f0a374c4a (patch)
tree9b81a900f2a90ca21100f454a1906a51f964e1fa
parente2a868a8437ea9ef2cf88a5b934b28da2b8f425d (diff)
comirror: Also fix utf8 handling
-rwxr-xr-xbin/comirror1
1 files changed, 1 insertions, 0 deletions
diff --git a/bin/comirror b/bin/comirror
index 106e7c3..378c171 100755
--- a/bin/comirror
+++ b/bin/comirror
@@ -96,6 +96,7 @@ sub file_to_hash {
}
open(my $fh, '<', $file) or die("Cannot read $file: $!\n");
+ binmode($fh, ':utf8');
while(my $line = <$fh>) {
$line =~ / ^ (?<key> \S+ ) [[:space:]]+ (?<value> .*) $ /x or next;
$return{$+{key}} = $+{value};