Package: libmp3-tag-perl
Version: 0.9709-2

There seems to be a problem in ID3v2.pm reading new version 2.4 tags.
The error message I got is

Unknown ID3v2-Tag version: v2.4.0
| 4 > 4 || 1 == 0
| 0,0,1,1,1n0: 0
1: 0
2: 1
3: 1
4: 1
Use of uninitialized value in concatenation (.) or string at
        /usr/share/perl5/MP3/Tag/ID3v2.pm line 1699 (#1)
    (W uninitialized) An undefined value was used as if it were already
    defined.  It was interpreted as a "" or a 0, but maybe it was a mistake.
    To suppress this warning assign a defined value to your variables.

    To help you figure out what was undefined, perl tells you what operation
    you used the undefined value in.  Note, however, that perl optimizes your
    program and the operation displayed in the warning may not necessarily
    appear literally in your program.  For example, "that $foo" is
    usually optimized into "that " . $foo, and the warning will refer to
    the concatenation (.) operator, even though there is no . in your
    program.

5:

Looking through the code it appears that the array in question
is defined for version 2.4. Looks like an off-by-one to me.
Attached you can find a patch.


Regards

Harri

--- libmp3-tag-perl-0.9709.orig/Tag/ID3v2.pm
+++ libmp3-tag-perl-0.9709/Tag/ID3v2.pm
@@ -1692,7 +1692,7 @@
 		# extract the header data
 		my ($major, $revision, $pflags) = unpack ("x3CCC", $header);
 		# check the version
-		if ($major >= $#supported_majors or $supported_majors[$major] == 0) {
+		if ($major > $#supported_majors or $supported_majors[$major] == 0) {
 			warn "Unknown ID3v2-Tag version: v2.$major.$revision\n";
 			print "| $major > ".($#supported_majors)." || $supported_majors[$major] == 0\n";
 			print "| ",join(",",@supported_majors),"n";

Reply via email to