Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

readpipe() broken: 2 bugs #2793

Closed
p5pRT opened this issue Nov 1, 2000 · 6 comments

Comments

@p5pRT
Copy link
Collaborator

@p5pRT p5pRT commented Nov 1, 2000

Migrated from rt.perl.org#4574 (status was 'resolved')

Searchable as RT4574$

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Nov 1, 2000

From ilya@math.ohio-state.edu

This is a bug report for perl from ilya@​monk.mps.ohio-state.edu,
generated with the help of perlbug 1.32 running under perl v5.7.0.

  ./perl -wle 'print readpipe($^X, "-e", q(printp "12\n"))'
  sh​: printp​: not found
  ./perl-e

I can see 2 bugs here​:

  a) readpipe is not a list operator, as it should be (see my patch
  which made it a list operator);

  b) ($^X, '-e') "leak" to print().

Ilya


Flags​:
  category=core
  severity=low


Site configuration information for perl v5.7.0​:

Configured by ilya at Tue Sep 26 23​:09​:09 EDT 2000.

Summary of my perl5 (revision 5.0 version 7 subversion 0) configuration​:
  Platform​:
  osname=solaris, osvers=2.8, archname=sun4-solaris
  uname='sunos monk 5.8 generic sun4u sparc '
  config_args='-des -D usedevel'
  hint=recommended, useposix=true, d_sigaction=define
  usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
  useperlio=undef d_sfio=undef uselargefiles=define usesocks=undef
  use64bitint=undef use64bitall=undef uselongdouble=undef
  Compiler​:
  cc='cc', ccflags ='-I/usr/local/include -I/opt/local/include -I/opt/gnu/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O', cppflags='-I/usr/local/include -I/opt/local/include -I/opt/gnu/include'
  ccversion='WorkShop Compilers 5.0 98/12/15 C 5.0', gccversion='', gccosandvers=''
  intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=4321
  d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16
  ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
  alignbytes=8, usemymalloc=y, prototype=define
  Linker and Libraries​:
  ld='cc', ldflags =' -L/usr/local/lib -L/opt/local/lib -L/opt/gnu/lib -L/opt/SUNWspro/SC5.0/lib '
  libpth=/usr/local/lib /opt/local/lib /opt/gnu/lib /opt/SUNWspro/SC5.0/lib /lib /usr/lib /usr/ccs/lib
  libs=-lsocket -lnsl -lgdbm -ldl -lm -lc -lcrypt -lsec
  libc=/lib/libc.so, so=so, useshrplib=false, libperl=libperl.a
  Dynamic Linking​:
  dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags=' '
  cccdlflags='-KPIC', lddlflags='-G -L/usr/local/lib -L/opt/local/lib -L/opt/gnu/lib -L/opt/SUNWspro/SC5.0/lib'

Locally applied patches​:
 


@​INC for perl v5.7.0​:
  lib
  /home/ilya/perl
  /home/ilya/perl/lib/perl5/site_perl/5.005
  /home/ilya/perl/lib/perl5
  /home/ilya/perl/lib/perl5/site_perl
  /home/ilya/perl/lib/perl5/site_perl/sun4-solaris
  /home/ilya/perl/lib/perl5/site_perl/5.005/sun4-solaris
  /home/ilya/perl/lib/perl5/5.00503/
  /usr/local/lib/perl5/5.7.0/sun4-solaris
  /usr/local/lib/perl5/5.7.0
  /usr/local/lib/perl5/site_perl/5.7.0/sun4-solaris
  /usr/local/lib/perl5/site_perl/5.7.0
  /usr/local/lib/perl5/site_perl/5.6.0/sun4-solaris
  /usr/local/lib/perl5/site_perl/5.6.0
  /usr/local/lib/perl5/site_perl/5.005/sun4-solaris
  /usr/local/lib/perl5/site_perl/5.005
  /usr/local/lib/perl5/site_perl
  .


Environment for perl v5.7.0​:
  HOME=/home/ilya
  LANG=en_US.ISO8859-1
  LANGUAGE (unset)
  LC_COLLATE=en_US.ISO8859-1
  LC_CTYPE=en_US.ISO8859-1
  LC_MESSAGES=C
  LC_MONETARY=en_US.ISO8859-1
  LC_NUMERIC=en_US.ISO8859-1
  LC_TIME=en_US.ISO8859-1
  LD_LIBRARY_PATH=/opt/local/lib​:/usr/openwin/lib​:/opt/local/lib/rvplayer5.0​:/opt/X11/lib​:/opt/local/lib​:/usr/openwin/lib​:/opt/local/lib/rvplayer5.0​:/opt/X11/lib​:/opt/local/lib​:/usr/openwin/lib​:/opt/local/lib/rvplayer5.0​:/opt/X11/lib
  LOGDIR (unset)
  PATH=/home/ilya/bin​:/opt/SUNWspro/bin​:/usr/dt/bin​:/usr/ccs/bin​:/usr/java/bin​:/opt/netscape​:/opt/microsoft/bin​:/opt/Office52/program​:/opt/gnu/bin​:/usr/openwin/bin​:/opt/X11/bin​:/home/tex/bin​:/opt/local/bin​:/usr/bin​:/opt/local/games​:/opt/unsup/ilya/bin​:.
  PERLLIB=/home/ilya/perl​:/home/ilya/perl/lib/perl5/site_perl/5.005​:/home/ilya/perl/lib/perl5​:/home/ilya/perl/lib/perl5/site_perl​:/home/ilya/perl/lib/perl5/site_perl/sun4-solaris​:/home/ilya/perl/lib/perl5/site_perl/5.005/sun4-solaris​:/home/ilya/perl/lib/perl5/5.00503/
  PERL_BADLANG (unset)
  SHELL=/bin/tcsh

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Aug 17, 2013

From @mauke

On Wed Nov 01 09​:14​:00 2000, ilya@​math.ohio-state.edu wrote​:

./perl -wle 'print readpipe($^X, "-e", q(printp "12\n"))'
sh​: printp​: not found
./perl-e

I can see 2 bugs here​:

a) readpipe is not a list operator, as it should be (see my patch
which made it a list operator);

b) ($^X, '-e') "leak" to print().

First off, this bug still exists in 5.19.

Second, you can also get the inverse of b), i.e. stealing args from print​:

% perl -we 'print "Just ", "echo another Perl hacker,", readpipe +()'
Just another Perl hacker,

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Dec 12, 2017

From zefram@fysh.org

Argument list handling fixed in commit
397baf2. That readpipe() is not a
list operator is not a bug​: it's documented to take a single expression,
and most of the internals thought it was a unary operator. If you want a
list version of readpipe(), that would be a feature request that should be
raised separately. It would probably be a bad idea to turn the existing
readpipe() into a list operator​: the list version should be distinct.

-zefram

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Dec 12, 2017

@xsawyerx - Status changed from 'open' to 'pending release'

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Jun 23, 2018

From @khwilliamson

Thank you for filing this report. You have helped make Perl better.

With the release yesterday of Perl 5.28.0, this and 185 other issues have been
resolved.

Perl 5.28.0 may be downloaded via​:
https://metacpan.org/release/XSAWYERX/perl-5.28.0

If you find that the problem persists, feel free to reopen this ticket.

@p5pRT

This comment has been minimized.

Copy link
Collaborator Author

@p5pRT p5pRT commented Jun 23, 2018

@khwilliamson - Status changed from 'pending release' to 'resolved'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.