r3333 - /packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch

ntyni-guest at users.alioth.debian.org ntyni-guest at users.alioth.debian.org
Thu Jul 27 19:10:33 UTC 2006


Author: ntyni-guest
Date: Thu Jul 27 19:10:31 2006
New Revision: 3333

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=3333
Log:
Update mbox locking patch.

Modified:
    packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch

Modified: packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch
URL: http://svn.debian.org/wsvn/pkg-perl/packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch?rev=3333&op=diff
==============================================================================
--- packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch (original)
+++ packages/libemail-localdelivery-perl/trunk/debian/patches/10mbox-locking.dpatch Thu Jul 27 19:10:31 2006
@@ -6,18 +6,18 @@
 
 @DPATCH@
 diff -urNad trunk~/LocalDelivery/Mbox.pm trunk/LocalDelivery/Mbox.pm
---- trunk~/LocalDelivery/Mbox.pm	2005-12-20 00:42:20.000000000 +0200
-+++ trunk/LocalDelivery/Mbox.pm	2005-12-21 15:08:47.051099165 +0200
+--- trunk~/LocalDelivery/Mbox.pm	2006-07-27 22:10:49.000000000 +0300
++++ trunk/LocalDelivery/Mbox.pm	2006-07-27 22:11:02.000000000 +0300
 @@ -2,7 +2,7 @@
  use File::Path;
  use File::Basename;
  use Email::Simple;
 -use Fcntl ':flock';
 +use Fcntl qw(:DEFAULT :seek);
+ use Symbol qw(gensym);
  
- our $VERSION = "1.07";
- 
-@@ -15,7 +15,7 @@
+ use vars qw($VERSION);
+@@ -17,7 +17,7 @@
          print $fh $class->_from_line(\$mail); # Avoid passing $mail where poss.
          print $fh $class->_escape_from_body(\$mail);
          print $fh "\n" unless $mail =~ /\n$/;
@@ -26,10 +26,10 @@
          push @rv, $file
      }
      return @rv;
-@@ -27,14 +27,14 @@
-     return if ! -d $dir and not mkpath($dir);
+@@ -30,14 +30,14 @@
  
-     open my $fh, ">> $file" or return;
+     my $fh = gensym;
+     open $fh, ">> $file" or return;
 -    $class->getlock($fh) || return;
 +    $class->getlock($fh, $file) || return;
      seek $fh, 0, 2;
@@ -44,7 +44,7 @@
      close $fh           or return;
      return 1;
  }
-@@ -79,17 +79,69 @@
+@@ -82,17 +82,69 @@
  }
  
  sub getlock {




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