Skip Menu |

This queue is for tickets about the PAR-Dist CPAN distribution.

Report information
The Basics
Id: 4028
Status: resolved
Priority: 0/
Queue: PAR-Dist

People
Owner: Nobody in particular
Requestors: ekolve [...] comcast.net
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: print() on closed filehandle META
I get the following warning occasionally when when building a par file. print() on closed filehandle META at /usr/lib/perl5/site_perl/5.8.0/PAR/Dist.pm line 168. It looks like on line 134 the old file is opened (would it make sense to do a stat here to ensure that exists?) and its results copied to the new META file. Both the META and OLD_META fh are closed at the end of the condition, but a new set of data is written on the META handle on line 168. I can't quite figure out why its necessary to use the old file and not write anew each time... Anway, I would either move the second print into the else block or do an unlink if the file exists prior to opening the file. thanks, --eric
Subject: Re: [cpan #4028] print() on closed filehandle META
From: Autrijus Tang <autrijus [...] autrijus.org>
To: bug-PAR-Dist [...] rt.cpan.org
Date: Mon, 06 Oct 2003 18:15:35 +0100
RT-Send-Cc:
?b 一, 2003-10-06 17:00, Guest via RT ?g?D?G Show quoted text
> I can't quite figure out why its necessary to use the old file and not > write anew each time...
Because I'd like to preserve old META.yml file, if any. Show quoted text
> Anway, I would either move the second print into the else block or do > an unlink if the file exists prior to opening the file.
Thanks, I've changed so it checks for fileno(META) before printing to it. It will be released shortly in a new version of PAR::Dist. Cheers, /Autrijus/