develooper Front page | perl.perl5.porters | Postings from September 2013

[perl #119755] [PATCH] 298de04 File::Find: diagnostics in case of a failed chdir

Thread Previous
From:
slaven @ rezic . de
Date:
September 12, 2013 14:58
Subject:
[perl #119755] [PATCH] 298de04 File::Find: diagnostics in case of a failed chdir
Message ID:
rt-3.6.HEAD-1873-1378997887-1788.119755-75-0@perl.org
# New Ticket Created by  slaven@rezic.de 
# Please include the string:  [perl #119755]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org:443/rt3/Ticket/Display.html?id=119755 >


This is a bug report for perl from slaven@rezic.de,
generated with the help of perlbug 1.39 running under perl 5.12.4.

>From 298de04af95a10589a2d6c1d13658e4d2df0d648 Mon Sep 17 00:00:00 2001
From: Slaven Rezic <slaven@rezic.de>
Date: Thu, 12 Sep 2013 14:04:27 +0200
Subject: [PATCH] File::Find: diagnostics in case of a failed chdir
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="------------1.8.1.2"

This is a multi-part message in MIME format.
--------------1.8.1.2
Content-Type: text/plain; charset=UTF-8; format=fixed
Content-Transfer-Encoding: 8bit

---
 ext/File-Find/lib/File/Find.pm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


--------------1.8.1.2
Content-Type: text/x-patch; name="0001-File-Find-diagnostics-in-case-of-a-failed-chdir.patch"
Content-Transfer-Encoding: 8bit
Content-Disposition: attachment; filename="0001-File-Find-diagnostics-in-case-of-a-failed-chdir.patch"

diff --git a/ext/File-Find/lib/File/Find.pm b/ext/File-Find/lib/File/Find.pm
index 99b868e..a179998 100644
--- a/ext/File-Find/lib/File/Find.pm
+++ b/ext/File-Find/lib/File/Find.pm
@@ -3,7 +3,7 @@ use 5.006;
 use strict;
 use warnings;
 use warnings::register;
-our $VERSION = '1.24';
+our $VERSION = '1.25';
 require Exporter;
 require Cwd;
 
@@ -809,7 +809,7 @@ sub _find_dir($$$) {
 		else {
 		    $tmp = join('/',('..') x ($CdLvl-$Level));
 		}
-		die "Can't cd to $tmp from $dir_name"
+		die "Can't cd to $tmp from $dir_name: $!"
 		    unless chdir ($tmp);
 		$CdLvl = $Level;
 	    }

--------------1.8.1.2--


---
Flags:
    category=library
    severity=low
    module=File::Find
---
Site configuration information for perl 5.12.4:

Configured by eserte at Wed Jan 23 20:07:25 CET 2013.

Summary of my perl5 (revision 5 version 12 subversion 4) configuration:
   
  Platform:
    osname=freebsd, osvers=9.0-release, archname=amd64-freebsd
    uname='freebsd cvrsnica.herceg.de 9.0-release freebsd 9.0-release #0: tue jan 3 07:46:30 utc 2012 root@farrell.cse.buffalo.edu:usrobjusrsrcsysgeneric amd64 '
    config_args='-sde -Dprefix=/usr/local -Darchlib=/usr/local/lib/perl5/5.12.4/mach -Dprivlib=/usr/local/lib/perl5/5.12.4 -Dman3dir=/usr/local/lib/perl5/5.12.4/perl/man/man3 -Dman1dir=/usr/local/man/man1 -Dsitearch=/usr/local/lib/perl5/site_perl/5.12.4/mach -Dsitelib=/usr/local/lib/perl5/site_perl/5.12.4 -Dscriptdir=/usr/local/bin -Dsiteman3dir=/usr/local/lib/perl5/5.12.4/man/man3 -Dsiteman1dir=/usr/local/man/man1 -Ui_malloc -Ui_iconv -Uinstallusrbinperl -Dcc=cc -Duseshrplib -Dinc_version_list=none -Dccflags=-DAPPLLIB_EXP="/usr/local/lib/perl5/5.12.4/BSDPAN" -Doptimize=-O2 -pipe -fno-strict-aliasing -Ui_gdbm -Dusethreads=n -Dusemymalloc=n -Duse64bitint'
    hint=recommended, useposix=true, d_sigaction=define
    useithreads=undef, usemultiplicity=undef
    useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef
    use64bitint=define, use64bitall=define, uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='cc', ccflags ='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.12.4/BSDPAN" -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include',
    optimize='-O2 -pipe -fno-strict-aliasing',
    cppflags='-DAPPLLIB_EXP="/usr/local/lib/perl5/5.12.4/BSDPAN" -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include'
    ccversion='', gccversion='4.2.1 20070831 patched [FreeBSD]', gccosandvers=''
    intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
    ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='cc', ldflags ='-pthread -Wl,-E  -fstack-protector -L/usr/local/lib'
    libpth=/usr/lib /usr/local/lib
    libs=-lgdbm -lm -lcrypt -lutil
    perllibs=-lm -lcrypt -lutil
    libc=, so=so, useshrplib=true, libperl=libperl.so
    gnulibc_version=''
  Dynamic Linking:
    dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='  -Wl,-R/usr/local/lib/perl5/5.12.4/mach/CORE'
    cccdlflags='-DPIC -fPIC', lddlflags='-shared  -L/usr/local/lib -fstack-protector'

Locally applied patches:
    

---
@INC for perl 5.12.4:
    /usr/local/lib/perl5/5.12.4/BSDPAN
    /usr/local/lib/perl5/site_perl/5.12.4/mach
    /usr/local/lib/perl5/site_perl/5.12.4
    /usr/local/lib/perl5/5.12.4/mach
    /usr/local/lib/perl5/5.12.4
    .

---
Environment for perl 5.12.4:
    HOME=/home/e/eserte
    LANG (unset)
    LANGUAGE (unset)
    LC_ALL=de_DE.UTF-8
    LD_LIBRARY_PATH (unset)
    LOGDIR (unset)
    PATH=/usr/local/bin:/usr/X11R6/bin:/usr/X11/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/e/eserte/bin/freebsd9.0:/home/e/eserte/bin/sh:/home/e/eserte/bin:/usr/games:/home/e/eserte/devel
    PERLDOC=-MPod::Perldoc::ToTextOverstrike
    PERL_BADLANG (unset)
    PERL_HTML_DISPLAY_CLASS=HTML::Display::Mozilla
    SHELL=/usr/local/bin/zsh


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About