Skip Menu |

This queue is for tickets about the File-Util CPAN distribution.

Report information
The Basics
Id: 52319
Status: resolved
Priority: 0/
Queue: File-Util

People
Owner: Nobody in particular
Requestors: mmcginn [...] rogers.com
Cc:
AdminCc:

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



Subject: File-Util-3.27 bug
Date: Tue, 1 Dec 2009 05:51:33 -0800 (PST)
To: bug-File-Util [...] rt.cpan.org
From: MICHAEL MCGINN <mmcginn [...] rogers.com>
Hi Tommy, I'm having an issue with the error handling and how to stop the 'list_dir' method from aborting on a directory which contains another directory owned by another user; example: root ownership with permissions 'drwx------'. I was expecting to be able to capture and bypass the error/warning given what's indicated in the documentation. Regards, Michael --------------------------------------------------------------------------- uname -a Linux dune 2.6.18-164.6.1.el5.centos.plus #1 SMP Wed Nov 4 09:31:39 EST 2009 x86_64 x86_64 x86_64 GNU/Linux perl -version This is perl, v5.10.1 built for x86_64-linux-thread-multi (with 2 registered patches, see perl -V for more detail) File-Util-3.27 ----- code #!/opt/ActivePerl-5.10/bin/perl use strict; use warnings; use File::Util; my $fu = File::Util->new('--fatals-as-warning'); my @directories = $fu->list_dir('/home/mmcginn', '--files-only', '--recurse',); --------------------------------------- Show quoted text
----- ERROR -------------- File::Util can't opendir on directory: »/home/user/.dbus« The system returned this error: »Permission denied« Origin: Could be either human _or_ system error. Solution: Cannot diagnose. A Human must investigate the problem. 1. File::Util::list_dir -called at line (266) of /opt/ActivePerl-5.10/site/lib/File/Util.pm -was called with args -was not called to evaluate anything 2. File::Util::list_dir -called at line (10) of /home/user/Scripts/file_util.pl -was called with args -was not called to evaluate anything Can't use an undefined value as an ARRAY reference at /opt/ActivePerl-5.10/site/lib/File/Util.pm line 274. ----------------------------------------------
I'll be taking steps to fix this. Obviously, File::Util should not have thrown an exception when you told it to warn only. I'll let you know when it is resolved.
Resolved in 3.29
Pending upload to CPAN later today
Subject: File-Util-3.29.tar.gz
Download File-Util-3.29.tar.gz
application/x-gzip 44.8k

Message body not shown because it is not plain text.