From bd068145aad23a59ff605f268d7c06d1cf473df5 Mon Sep 17 00:00:00 2001 From: Reinhold Kainhofer Date: Sat, 17 Jul 2010 16:56:41 +0200 Subject: [PATCH] Allow empty key signature --- pae2xml.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pae2xml.pl b/pae2xml.pl index 0e8de94..929a576 100755 --- a/pae2xml.pl +++ b/pae2xml.pl @@ -161,7 +161,7 @@ sub parse_pe { $pe =~ s/@ü/@0ü/gs; # make missing time signature explicit while ($pe =~ s/([^\-])(\d+)(\'|\,)(A|B|C|D|E|F|G)/$1$3$2$4/gs) {}; # octave first, then duration. Truly global. - if ($pe =~ /\s*(%([\w\-\+\d]+))?(@([\d\w\/]+))?\s*&?\s*(\$([^ü]+))?ü(.*)$/gs) { + if ($pe =~ /^\s*(%([\w\-\+\d]+))?(@([\d\w\/]+))?\s*&?\s*(\$([^ü]*))?ü(.*)$/gs) { my ($clef, $timesig, $keysig, $rest) = ($2, $4, $6, $7); print "Writing $filename...\n"; -- 2.11.4.GIT