# New Ticket Created by "Todd Rinaldo" # Please include the string: [perl #132008] # in the subject line of all future correspondence about this issue. # <URL: https://rt.perl.org/Ticket/Display.html?id=132008 > This is a bug report for perl from toddr@cpan.org, generated with the help of perlbug 1.40 running under perl 5.26.0. ----------------------------------------------------------------- [Please describe your issue here] We just upgraded to 5.26.0 and noticed that an empty &STDERR file was getting created in one of our directories. The root cause was hard to track down because it only happened if /dev/tty was inaccessible. To re-produce this (probably only on POSIX systems), you can do: perl526 -MPOSIX -MTerm::ReadLine -E'exit if(fork); POSIX::setsid(); exit if(fork); my $t = Term::ReadLine->new("whatever")'; then ls -ld \&STDERR This problem bisects back to a conversion of a 2 arg open to a 3 arg open in 1ae6ead94905dfee43773cf3b18949c91b33f9d1 The problem is that redirecting file handles to STDERR (open (my $fh, ">&STDERR)) cannot be done as a 3 arg open or it'll actually try to write to that file. I suggest reverting the fix (Only for the one file dist/Term-ReadLine/lib/Term/ReadLine.pm) and also propose this be a maintenance fix in 5.26.1 Todd [Please do not change anything below this line] ----------------------------------------------------------------- --- Flags: category=library severity=medium module=Term::ReadLine --- Site configuration information for perl 5.26.0: Configured by cPanel at Tue Aug 22 13:29:24 CDT 2017. Summary of my perl5 (revision 5 version 26 subversion 0) configuration: Platform: osname=linux osvers=3.10.0-123.20.1.el7.x86_64 archname=x86_64-linux-64int uname='linux rpmbuild-64-centos-7.dev.cpanel.net 3.10.0-123.20.1.el7.x86_64 #1 smp thu jan 29 18:05:33 utc 2015 x86_64 x86_64 x86_64 gnulinux ' config_args='-des -Dusedevel -Darchname=x86_64-linux-64int -Dcc=/usr/bin/gcc -Dcpp=/usr/bin/cpp -Dusemymalloc=n -DDEBUGGING=none -Doptimize=-Os -Accflags=-m64 -Dccflags=-DPERL_DISABLE_PMC -fPIC -DPIC -I/usr/local/cpanel/3rdparty/perl/526/include -I/usr/local/cpanel/3rdparty/include -L/usr/local/cpanel/3rdparty/lib64 -Duseshrplib -Duselargefiles=yes -Duseposix=true -Dhint=recommended -Duseperlio=yes -Dcppflags=-I/usr/local/cpanel/3rdparty/perl/526/include -I/usr/local/cpanel/3rdparty/include -L/usr/local/cpanel/3rdparty/lib64 -Dldflags=-L/usr/local/cpanel/3rdparty/lib64 -Dprefix=/usr/local/cpanel/3rdparty/perl/526 -Dsiteprefix=/opt/cpanel/perl5/526 -Dsitebin=/opt/cpanel/perl5/526/bin -Dsitelib=/opt/cpanel/perl5/526/site_lib -Dusevendorprefix=true -Dvendorbin=/usr/local/cpanel/3rdparty/perl/526/bin -Dvendorprefix=/usr/local/cpanel/3rdparty/perl/526/lib64/perl5 -Dvendorlib=/usr/local/cpanel/3rdparty/perl/526/lib64/perl5/cpanel_lib -Dprivlib=/usr/local/cpanel/3rdparty/perl/526/lib64/perl5/5.26.0 -Dman1dir=none -Dman3dir=none -Dscriptdir=/usr/local/cpanel/3rdparty/perl/526/bin -Dscriptdirexp=/usr/local/cpanel/3rdparty/perl/526/bin -Dsiteman1dir=none -Dsiteman3dir=none -Dinstallman1dir=none -Dversiononly=no -Dinstallusrbinperl=no -Dcf_by=cPanel -Dmyhostname=localhost -Dperladmin=root@localhost -Dcf_email=support@cpanel.net -Di_dbm=/usr/local/cpanel/3rdparty/include -Di_gdbm=/usr/local/cpanel/3rdparty/include -Di_ndbm=/usr/local/cpanel/3rdparty/include -DDB_File=true -Ud_dosuid -Uuserelocatableinc -Umad -Uusethreads -Uusemultiplicity -Uusesocks -Uuselongdouble -Aldflags=-L/usr/local/cpanel/3rdparty/lib64 -L/usr/lib64 -L/lib64 -lgdbm -Dlocincpth=/usr/local/cpanel/3rdparty/perl/526/include /usr/local/cpanel/3rdparty/include /usr/local/include -Duse64bitint -Uuse64bitall -Dlibpth=/usr/local/cpanel/3rdparty/lib64 /usr/local/lib64 /usr/local/lib /lib64 /usr/lib64 ' hint=recommended useposix=true d_sigaction=define useithreads=undef usemultiplicity=undef use64bitint=define use64bitall=undef uselongdouble=undef usemymalloc=n default_inc_excludes_dot=define bincompat5005=undef Compiler: cc='/usr/bin/gcc' ccflags ='-DPERL_DISABLE_PMC -fPIC -DPIC -I/usr/local/cpanel/3rdparty/perl/526/include -I/usr/local/cpanel/3rdparty/include -L/usr/local/cpanel/3rdparty/lib64 -m64 -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_FORTIFY_SOURCE=2' optimize='-Os' cppflags='-I/usr/local/cpanel/3rdparty/perl/526/include -I/usr/local/cpanel/3rdparty/include -L/usr/local/cpanel/3rdparty/lib64 -DPERL_DISABLE_PMC -fPIC -DPIC -I/usr/local/cpanel/3rdparty/perl/526/include -I/usr/local/cpanel/3rdparty/include -L/usr/local/cpanel/3rdparty/lib64 -m64 -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include' ccversion='' gccversion='4.8.2 20140120 (Red Hat 4.8.2-16)' gccosandvers='' intsize=4 longsize=8 ptrsize=8 doublesize=8 byteorder=12345678 doublekind=3 d_longlong=define longlongsize=8 d_longdbl=define longdblsize=16 longdblkind=3 ivtype='long' ivsize=8 nvtype='double' nvsize=8 Off_t='off_t' lseeksize=8 alignbytes=8 prototype=define Linker and Libraries: ld='/usr/bin/gcc' ldflags ='-L/usr/local/cpanel/3rdparty/lib64 -L/usr/local/cpanel/3rdparty/lib64 -L/usr/lib64 -L/lib64 -lgdbm -fstack-protector-strong -L/usr/local/lib' libpth=/usr/local/cpanel/3rdparty/lib64 /usr/local/lib64 /usr/local/lib /lib64 /usr/lib64 /usr/local/lib /usr/lib /lib/../lib64 /usr/lib/../lib64 /lib libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc libc=libc-2.17.so so=so useshrplib=true libperl=libperl.so gnulibc_version='2.17' Dynamic Linking: dlsrc=dl_dlopen.xs dlext=so d_dlsymun=undef ccdlflags='-Wl,-E -Wl,-rpath,/usr/local/cpanel/3rdparty/perl/526/lib64/perl5/5.26.0/x86_64-linux-64int/CORE' cccdlflags='-fPIC' lddlflags='-shared -Os -L/usr/local/cpanel/3rdparty/lib64 -L/usr/lib64 -L/lib64 -L/usr/local/lib -fstack-protector-strong' Locally applied patches: cPanel patches cPanel INC path changes cPanel performance improvements to modules cPanel Immortal COW cPanel B and O performance fixups cPanel B::C Declare Static Memory malloc patches cPanel Disable XS handshake --- @INC for perl 5.26.0: /usr/local/cpanel /usr/local/cpanel/3rdparty/perl/526/lib64/perl5/cpanel_lib/x86_64-linux-64int /usr/local/cpanel/3rdparty/perl/526/lib64/perl5/cpanel_lib /usr/local/cpanel/3rdparty/perl/526/lib64/perl5/5.26.0/x86_64-linux-64int /usr/local/cpanel/3rdparty/perl/526/lib64/perl5/5.26.0 /opt/cpanel/perl5/526/site_lib/x86_64-linux-64int /opt/cpanel/perl5/526/site_lib --- Environment for perl 5.26.0: HOME=/root LANG=en_US.UTF-8 LANGUAGE (unset) LD_LIBRARY_PATH (unset) LOGDIR (unset) PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin PERL_BADLANG (unset) SHELL=/bin/zshThread Previous | Thread Next