r14190 - in /trunk/libmail-sendeasy-perl/debian: changelog control patches/001_plus-in-emailaddress.dpatch

menole-guest at users.alioth.debian.org menole-guest at users.alioth.debian.org
Tue Feb 5 17:04:27 UTC 2008


Author: menole-guest
Date: Tue Feb  5 17:04:27 2008
New Revision: 14190

URL: http://svn.debian.org/wsvn/?sc=1&rev=14190
Log:
debian/control: Added dependency on libmail-rfc822-address-perl
debian/patches/001_plus-in-emailaddress.dpatch: Email address syntax check via Mail::RFC822::Address
debian/changelog: Setting distribution to 'unstable'

Modified:
    trunk/libmail-sendeasy-perl/debian/changelog
    trunk/libmail-sendeasy-perl/debian/control
    trunk/libmail-sendeasy-perl/debian/patches/001_plus-in-emailaddress.dpatch

Modified: trunk/libmail-sendeasy-perl/debian/changelog
URL: http://svn.debian.org/wsvn/trunk/libmail-sendeasy-perl/debian/changelog?rev=14190&op=diff
==============================================================================
--- trunk/libmail-sendeasy-perl/debian/changelog (original)
+++ trunk/libmail-sendeasy-perl/debian/changelog Tue Feb  5 17:04:27 2008
@@ -1,11 +1,9 @@
-libmail-sendeasy-perl (1.2-1) UNRELEASED; urgency=low
+libmail-sendeasy-perl (1.2-1) unstable; urgency=low
 
-  NOTE: the idea of what a valid local part is doesn't conform to RFC822
-  cf. http://lists.debian.org/debian-perl/2008/02/msg00035.html
-  
   [Michael Mende]
   * Initial Release (Closes: #464046).
-  * Patch Sendeasy.pm to accept '+' in localpart.
+  * Patch Sendeasy.pm to accept '+' in localpart,
+    let Mail::RFC822::Address do the address syntax check.
   * Patch Sendeasy.pm to handle html-only messages.
 
  -- Michael Mende <debian at menole.net>  Tue, 05 Feb 2008 09:43:49 +0000

Modified: trunk/libmail-sendeasy-perl/debian/control
URL: http://svn.debian.org/wsvn/trunk/libmail-sendeasy-perl/debian/control?rev=14190&op=diff
==============================================================================
--- trunk/libmail-sendeasy-perl/debian/control (original)
+++ trunk/libmail-sendeasy-perl/debian/control Tue Feb  5 17:04:27 2008
@@ -12,9 +12,9 @@
 
 Package: libmail-sendeasy-perl
 Architecture: all
-Depends: ${perl:Depends}
+Depends: ${perl:Depends}, libmail-rfc822-address-perl
 Description: Send plain/html e-mails through SMTP servers
  This modules will send in a easy way e-mails, and doesn't have 
- dependencies. Soo, you don't need to install libnet.
+ dependencies on libnet packages.
  .
  It supports SMTP authentication and attachments.

Modified: trunk/libmail-sendeasy-perl/debian/patches/001_plus-in-emailaddress.dpatch
URL: http://svn.debian.org/wsvn/trunk/libmail-sendeasy-perl/debian/patches/001_plus-in-emailaddress.dpatch?rev=14190&op=diff
==============================================================================
--- trunk/libmail-sendeasy-perl/debian/patches/001_plus-in-emailaddress.dpatch (original)
+++ trunk/libmail-sendeasy-perl/debian/patches/001_plus-in-emailaddress.dpatch Tue Feb  5 17:04:27 2008
@@ -1,26 +1,36 @@
 #! /bin/sh /usr/share/dpatch/dpatch-run
 ## 001_plus-in-emailaddress.dpatch by Michael Mende <debian at menole.net>
-## after suggestion by unknown found in http://rt.cpan.org/Public/Bug/Display.html?id=9724
 ## 
 ##
 ## All lines beginning with `## DP:' are a description of the patch.
-## DP: The e-mail syntax checker does not handle plus signs in usernames
-## DP: like "my+imap at example.com".
+## DP: The e-mail syntax checker does not handle plus signs in usernames.
+## DP: Let Mail::RFC822::Address do the address syntax check.
 
 diff -urNad /tmp/SendEasy.pm libmail-sendeasy-perl-1.2/lib/Mail/SendEasy.pm
 --- /tmp/SendEasy.pm	2004-04-09 07:48:46.000000000 +0000
 +++ libmail-sendeasy-perl-1.2/lib/Mail/SendEasy.pm	2008-02-05 10:12:12.000000000 +0000
-@@ -446,10 +446,10 @@
+@@ -17,6 +17,7 @@
+ no warnings ;
+ 
+ use vars qw($VERSION @ISA) ;
++use Mail::RFC822::Address qw(valid);
+ 
+ $VERSION = '1.2' ;
+ 
+@@ -444,15 +446,7 @@
    
-   my $stat = 1 ;
+   my ( $mail ) = @_ ;
    
+-  my $stat = 1 ;
+-  
 -  if ($mail !~ /^[\w\.-]+\@localhost$/gsi) {
 -    if ($mail !~ /^[\w\.-]+\@(?:[\w-]+\.)*?(?:\w+(?:-\w+)*)(?:\.\w+)+$/ ) { $stat = undef ;}
-+  if ($mail !~ /^[\w\.+-]+\@localhost$/gsi) {
-+    if ($mail !~ /^[\w\.+-]+\@(?:[\w-]+\.)*?(?:\w+(?:-\w+)*)(?:\.\w+)+$/ ) { $stat = undef ;}
-   }
+-  }
 -  elsif ($mail !~ /^[\w\.-]+\@[\w-]+$/ ) { $stat = undef ;}
-+  elsif ($mail !~ /^[\w\.+-]+\@[\w-]+$/ ) { $stat = undef ;}
-   
-   return 1 if $stat ;
-   return undef ;
+-  
+-  return 1 if $stat ;
+-  return undef ;
++  return Mail::RFC822::Address::valid($mail) ? 1 : undef;
+ }
+ 
+ ################




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