+moreutils (0.22) unstable; urgency=low
+
+ * vidir, zrun: Don't put temp files in the current directory. Closes: #429367
+
+ -- Joey Hess <joeyh@debian.org> Mon, 25 Jun 2007 16:08:14 -0400
+
moreutils (0.21) unstable; urgency=low
* Patch from Sergej Pupykin fixing ifdata -pN.
=cut
+use File::Spec;
use File::Temp;
use Getopt::Long;
}
}
-my $tmp=File::Temp->new(template => "dirXXXXX");
+my $tmp=File::Temp->new(TEMPLATE => "dirXXXXX", DIR => File::Spec->tmpdir);
open (OUT, ">".$tmp->filename) || die "$0: cannot write ".$tmp->filename.": $!\n";
my %item;
use warnings;
use strict;
use IO::Handle;
+use File::Spec;
use File::Temp qw{tempfile};
my $program = shift;
my $suffix = "-$2";
my @preprocess = $3 eq "bz2" ? qw(bzip2 -d -c) : qw(gzip -d -c);
- my ($fh, $tmpname) = tempfile(SUFFIX => $suffix, UNLINK => 1)
+ my ($fh, $tmpname) = tempfile(SUFFIX => $suffix,
+ DIR => File::Spec->tmpdir, UNLINK => 1)
or die "zrun: cannot create temporary file: $!\n";
if (my $child = fork) {