Upgrade to Encode 1.69.
[p5sagit/p5-mst-13.2.git] / ext / Encode / lib / Encode / Guess.pm
index b106a04..f4bfbfa 100644 (file)
@@ -2,7 +2,7 @@ package Encode::Guess;
 use strict;
 
 use Encode qw(:fallbacks find_encoding);
-our $VERSION = do { my @r = (q$Revision: 1.5 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+our $VERSION = do { my @r = (q$Revision: 1.6 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
 
 my $Canon = 'Guess';
 our $DEBUG = 0;
@@ -87,7 +87,7 @@ sub guess {
        $DEBUG and warn "Added: ", $e->name;
     }
     my $nline = 1;
-    for my $line (split /\r|\n|\r\n/, $octet){
+    for my $line (split /\r\n?|\n/, $octet){
        # cheat 2 -- \e in the string
        if ($line =~ /\e/o){
            my @keys = keys %try;