Subject: | IO::Interactive leaks temp files |
Date: | Tue, 25 Jul 2006 21:49:13 -0500 |
To: | Damian Conway <damian [...] conway.org>, bug-io-interactive [...] rt.cpan.org |
From: | Mike Sheehan <mjs3 [...] lucent.com> |
I tried using the IO::Interactive module (v0.0.3) from CPAN with Perl 5.6.1, but
it is creating and leaving behind an empty file in the current directory every
time it's used by a Perl script. It is doing this with Perl 5.6.1 on both
Solaris and Linux, but not with Perl 5.8.4. The file name is a random
stringified scalar reference. For example:
# ls -l
total 0
# perl -e 'use IO::Interactive'
# ls -l
total 0
-rw-r--r-- 1 root other 0 Jul 25 21:14 SCALAR(0x6a14c)
#
The problem appears to be caused by line 36 of the module:
open my $dev_null, '>', \do{my $dev_null};
Can you fix this so that IO::Interactive works correctly on Perl 5.6.1?
Unfortunately, we will not be able to upgrade our embedded systems to Perl 5.8
for the foreseeable future.
Thanks,
Mike Sheehan
Lucent Technologies