Skip Menu |

This queue is for tickets about the Archive-Tar CPAN distribution.

Report information
The Basics
Id: 121247
Status: resolved
Worked: 10 min
Priority: 0/
Queue: Archive-Tar

People
Owner: BINGOS [...] cpan.org
Requestors: xcdcdxcx [...] gmail.com
Cc:
AdminCc:

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



Subject: Archive::Tar->iter('0') fails because of a truthiness check of a supplied filename instead of a definedness check
Date: Wed, 19 Apr 2017 23:15:38 +0300
To: bug-Archive-Tar [...] rt.cpan.org
From: xcdc dxcx <xcdcdxcx [...] gmail.com>
'0' is a valid name for an archive and this should not happen. The bug is caused by this line in sub iter: my $filename = shift or return; I think it is better written as: my $filename = shift; return unless defined $filename;
On Wed Apr 19 16:15:57 2017, xcdcdxcx@gmail.com wrote: Show quoted text
> '0' is a valid name for an archive and this should not happen. > > The bug is caused by this line in sub iter: > > my $filename = shift or return; > > > I think it is better written as: > > > my $filename = shift; > > return unless defined $filename;
Thanks! I have made that change and uploaded 2.26 to CPAN.