]> git.donarmstrong.com Git - perltidy.git/commitdiff
update the patch for 862667 to match upstream's version and disable
authorDon Armstrong <don@donarmstrong.com>
Sun, 21 May 2017 19:33:53 +0000 (12:33 -0700)
committerDon Armstrong <don@donarmstrong.com>
Sun, 21 May 2017 19:33:53 +0000 (12:33 -0700)
debian/patches/die_on_unlink_failures
debian/patches/series

index c950d7e846ade74375cc79467bc56a5b54a7cd9a..7b4d3d99116955fbe34d72d72066d3782f80a5c4 100644 (file)
@@ -1,27 +1,31 @@
 Description: die if perltidy.ERR and other temporary files cannot be unlinked
-Origin: vendor, https://bugs.debian.org/862667
-Author: Don Armstrong <don@debian.org>
+Origin: Upstream, Cherrypicked from 20170521.
+Author: Don Armstrong <don@debian.org>, Steve Hancock
+diff --git a/lib/Perl/Tidy.pm b/lib/Perl/Tidy.pm
+index 2b0df0e..edcec6d 100644
 --- a/lib/Perl/Tidy.pm
 +++ b/lib/Perl/Tidy.pm
-@@ -3692,7 +3692,9 @@
+@@ -3692,7 +3702,10 @@ sub do_syntax_check {
      # now wish for luck...
      my $msg = qx/perl $flags $quoted_stream_filename $error_redirection/;
  
 -    unlink $stream_filename if ($is_tmpfile);
-+    unlink $stream_filename or
-+        Perl::Tidy::Die("couldn't unlink stream ${stream_filename}: $!\n")
-+            if ($is_tmpfile);
++    if ($is_tmpfile) {
++        unlink $stream_filename
++          or Perl::Tidy::Die("couldn't unlink stream $stream_filename: $!\n");
++    }
      return $stream_filename, $msg;
  }
  
-@@ -4128,7 +4130,10 @@
+@@ -4128,7 +4143,11 @@ sub new {
  
      # remove any old error output file if we might write a new one
      unless ( $fh_warnings || ref($warning_file) ) {
 -        if ( -e $warning_file ) { unlink($warning_file) }
 +        if ( -e $warning_file ) {
-+            unlink($warning_file) or
-+                Perl::Tidy::Die("couldn't unlink warning file ${warning_file}: $!\n");
++            unlink($warning_file)
++              or Perl::Tidy::Die(
++                "couldn't unlink warning file $warning_file: $!\n");
 +        }
      }
  
index a54562cc7d262382b47ea90838b740cf1a8c3fd6..9b1049a47296ab6692d1a8e6e0f0b0528e0436a7 100644 (file)
@@ -1,2 +1 @@
-die_on_unlink_failures
 document_bst_better