open files in UTF-8 mode to help MARC::Batch
[migration-tools.git] / spit_unicorn_marc_holdings.pl
index a897e63..c99d1a1 100755 (executable)
@@ -30,7 +30,10 @@ foreach my $argnum ( 0 .. $#ARGV ) {
 
        print STDERR "Processing " . $ARGV[$argnum] . "\n";
 
-       my $batch = MARC::Batch->new('XML',$ARGV[$argnum]);
+    my $M;
+    open $M, '<:utf8', $ARGV[$argnum];
+    my $batch = MARC::Batch->new('XML',$M);
+
        $batch->strict_off();
        $batch->warnings_off();