r69201 - in /branches/upstream/libemail-mime-perl/current: Changes META.yml Makefile.PL lib/Email/MIME.pm lib/Email/MIME/Creator.pm lib/Email/MIME/Header.pm lib/Email/MIME/Modifier.pm t/encoding.t t/perl-minver.t

jawnsy-guest at users.alioth.debian.org jawnsy-guest at users.alioth.debian.org
Mon Feb 21 03:48:09 UTC 2011


Author: jawnsy-guest
Date: Mon Feb 21 03:47:58 2011
New Revision: 69201

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=69201
Log:
[svn-upgrade] new version libemail-mime-perl (1.907)

Modified:
    branches/upstream/libemail-mime-perl/current/Changes
    branches/upstream/libemail-mime-perl/current/META.yml
    branches/upstream/libemail-mime-perl/current/Makefile.PL
    branches/upstream/libemail-mime-perl/current/lib/Email/MIME.pm
    branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Creator.pm
    branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Header.pm
    branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Modifier.pm
    branches/upstream/libemail-mime-perl/current/t/encoding.t
    branches/upstream/libemail-mime-perl/current/t/perl-minver.t

Modified: branches/upstream/libemail-mime-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/Changes?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/Changes (original)
+++ branches/upstream/libemail-mime-perl/current/Changes Mon Feb 21 03:47:58 2011
@@ -1,4 +1,11 @@
 Revision history for Perl extension Email::MIME.
+
+1.907   2011-02-02
+
+        require 5.8.5 for sane encoding
+
+        be more lenient with Content-Tranfser-Encoding values; stop at
+        semicolons
 
 1.906   2010-10-07
         update our prereq on Test::More to 0.88

Modified: branches/upstream/libemail-mime-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/META.yml?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/META.yml (original)
+++ branches/upstream/libemail-mime-perl/current/META.yml Mon Feb 21 03:47:58 2011
@@ -1,6 +1,6 @@
 --- #YAML:1.0
 name:               Email-MIME
-version:            1.906
+version:            1.907
 abstract:           ~
 author:  []
 license:            perl

Modified: branches/upstream/libemail-mime-perl/current/Makefile.PL
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/Makefile.PL?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/Makefile.PL (original)
+++ branches/upstream/libemail-mime-perl/current/Makefile.PL Mon Feb 21 03:47:58 2011
@@ -1,4 +1,4 @@
-use 5.006; # see t/perl-minver.t
+use 5.8.5; # see t/perl-minver.t
 use strict;
 use warnings;
 use ExtUtils::MakeMaker;

Modified: branches/upstream/libemail-mime-perl/current/lib/Email/MIME.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/lib/Email/MIME.pm?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/lib/Email/MIME.pm (original)
+++ branches/upstream/libemail-mime-perl/current/lib/Email/MIME.pm Mon Feb 21 03:47:58 2011
@@ -1,4 +1,4 @@
-use 5.006;
+use 5.8.5;
 use strict;
 use warnings;
 
@@ -21,7 +21,7 @@
 
 =head1 VERSION
 
-version 1.906
+version 1.907
 
 =head1 SYNOPSIS
 
@@ -111,10 +111,14 @@
 
 =cut
 
-our $VERSION = '1.906';
-
-use vars qw[$CREATOR];
-$CREATOR = 'Email::MIME::Creator';
+our $VERSION = '1.907';
+
+our $CREATOR = 'Email::MIME::Creator';
+
+my $NO_ENCODE_RE = qr/
+  \A
+  (?:7bit|8bit|binary)\s*(?:;|$)
+/ix;
 
 sub new {
   my $self = shift->SUPER::new(@_);
@@ -296,7 +300,7 @@
 
   return $body unless $cte;
 
-  if (!$self->force_decode_hook and $cte =~ /\A(?:7bit|8bit|binary)\z/i) {
+  if (!$self->force_decode_hook and $cte =~ $NO_ENCODE_RE) {
     return $body;
   }
 
@@ -550,7 +554,7 @@
   # object. -- rjbs, 2007-07-16
   unless (((caller(1))[3] || '') eq 'Email::Simple::new') {
     $body = Email::MIME::Encodings::encode($enc, $body)
-      unless !$enc || $enc =~ /^(?:7bit|8bit|binary)\s*$/i;
+      unless !$enc || $enc =~ $NO_ENCODE_RE;
   }
 
   $self->{body_raw} = $body;

Modified: branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Creator.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Creator.pm?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Creator.pm (original)
+++ branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Creator.pm Mon Feb 21 03:47:58 2011
@@ -2,7 +2,7 @@
 use strict;
 
 use vars qw[$VERSION];
-$VERSION = '1.906';
+$VERSION = '1.907';
 
 use base q[Email::Simple::Creator];
 use Email::MIME;

Modified: branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Header.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Header.pm?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Header.pm (original)
+++ branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Header.pm Mon Feb 21 03:47:58 2011
@@ -3,7 +3,7 @@
 package Email::MIME::Header;
 use base 'Email::Simple::Header';
 
-our $VERSION = '1.906';
+our $VERSION = '1.907';
 
 use Encode 1.9801;
 

Modified: branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Modifier.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Modifier.pm?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Modifier.pm (original)
+++ branches/upstream/libemail-mime-perl/current/lib/Email/MIME/Modifier.pm Mon Feb 21 03:47:58 2011
@@ -4,7 +4,7 @@
 package Email::MIME::Modifier;
 
 use vars qw[$VERSION];
-$VERSION = '1.906';
+$VERSION = '1.907';
 
 use Email::MIME;
 
@@ -16,7 +16,7 @@
 
 =head1 VERSION
 
-version 1.906
+version 1.907
 
 =head1 PERL EMAIL PROJECT
 

Modified: branches/upstream/libemail-mime-perl/current/t/encoding.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/t/encoding.t?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/t/encoding.t (original)
+++ branches/upstream/libemail-mime-perl/current/t/encoding.t Mon Feb 21 03:47:58 2011
@@ -1,7 +1,21 @@
-use Test::More tests => 14;
+use Test::More tests => 20;
 
 use_ok 'Email::MIME';
 use_ok 'Email::MIME::Modifier';
+
+for my $encode ('7bit', '7bit; foo') {
+  my $email = Email::MIME->new(<<__MESSAGE__);
+Content-Transfer-Encoding: $encode
+Content-Type: text/plain
+
+Hello World!
+I like you!
+__MESSAGE__
+
+  is $email->body, qq[Hello World!\nI like you!\n], 'plain works';
+  is $email->body_raw, qq[Hello World!\nI like you!\n], 'plain raw works';
+  is $email->header('Content-Transfer-Encoding'), $encode, 'plain encoding works';
+}
 
 my $email = Email::MIME->new(<<__MESSAGE__);
 Content-Transfer-Encoding: 7bit

Modified: branches/upstream/libemail-mime-perl/current/t/perl-minver.t
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libemail-mime-perl/current/t/perl-minver.t?rev=69201&op=diff
==============================================================================
--- branches/upstream/libemail-mime-perl/current/t/perl-minver.t (original)
+++ branches/upstream/libemail-mime-perl/current/t/perl-minver.t Mon Feb 21 03:47:58 2011
@@ -10,4 +10,4 @@
 
 plan skip_all => "this test requires Test::MinimumVersion" if $@;
 
-all_minimum_version_ok(5.008);
+all_minimum_version_ok(5.008005);




More information about the Pkg-perl-cvs-commits mailing list