summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/perl/t/op/read.t
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/perl/t/op/read.t')
-rw-r--r--gnu/usr.bin/perl/t/op/read.t5
1 files changed, 1 insertions, 4 deletions
diff --git a/gnu/usr.bin/perl/t/op/read.t b/gnu/usr.bin/perl/t/op/read.t
index 8235bc20724..23f1b51a2c6 100644
--- a/gnu/usr.bin/perl/t/op/read.t
+++ b/gnu/usr.bin/perl/t/op/read.t
@@ -31,9 +31,7 @@ my $has_perlio = !eval {
!$Config::Config{useperlio}
};
-my $tmpfile = 'Op_read.tmp';
-
-END { 1 while unlink $tmpfile }
+my $tmpfile = tempfile();
my (@values, @buffers) = ('', '');
@@ -56,7 +54,6 @@ foreach my $value (@values) {
skip "Needs :utf8 layer but no perlio", 2 * @offsets * @lengths
if $utf8 and !$has_perlio;
- 1 while unlink $tmpfile;
open FH, ">$tmpfile" or die "Can't open $tmpfile: $!";
binmode FH, "utf8" if $utf8;
print FH $value;