From 7374d928fe95fa7ea93e2e8650da3a98bfce9738 Mon Sep 17 00:00:00 2001 From: dbs Date: Thu, 30 Apr 2009 15:23:38 +0000 Subject: [PATCH] Depending on when you process the XML, the annoying characters may be escaped git-svn-id: svn://svn.open-ils.org/ILS-Contrib/conifer/trunk@424 6d9bc8c9-1ec2-4278-b937-99fde70a366f --- tools/migration-scripts/fix_bad_marcxml.pl | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/migration-scripts/fix_bad_marcxml.pl b/tools/migration-scripts/fix_bad_marcxml.pl index 20f174cd1c..2e45dbd3c5 100644 --- a/tools/migration-scripts/fix_bad_marcxml.pl +++ b/tools/migration-scripts/fix_bad_marcxml.pl @@ -33,15 +33,18 @@ sub process_file { # # # This will at least enable MARC::File::XML to process it: - if ($_ =~ m##o) { + if ($_ =~ m##o or $_ =~ m##o ) { print STDERR "Bad subfield code \" at line $lineno of file $file\n"; $_ =~ s{}{}o; - } elsif ($_ =~ m##o) { + $_ =~ s{}{}o; + } elsif ($_ =~ m##o or $_ =~ m##o) { print STDERR "Bad subfield code < at line $lineno of file $file\n"; $_ =~ s{}{}o; - } elsif ($_ =~ m##o) { + $_ =~ s{}{}o; + } elsif ($_ =~ m##o or $_ =~ m##o) { print STDERR "Bad subfield code & at line $lineno of file $file\n"; $_ =~ s{}{}o; + $_ =~ s{}{}o; } elsif ($_ =~ m#