This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perform system() arg processing before fork
authorZefram <zefram@fysh.org>
Sat, 16 Dec 2017 05:33:20 +0000 (05:33 +0000)
committerZefram <zefram@fysh.org>
Sat, 16 Dec 2017 05:33:20 +0000 (05:33 +0000)
commit64def2aeaeb63f92dadc6dfa33486c1d7b311963
tree0c5733662aef0751a689d1c295154f4770a9fe7e
parent52e58e76455a7593547f41dc02823f4b5f83185c
perform system() arg processing before fork

A lot of things can happen when stringifying an argument list: side
effects, warnings, exceptions.  In the case of system(), these effects
should happen in the context of the parent process.  The stringification
can also depend on which process it happens in, as in the case of
$$, and in that case it should also happen in the parent process.
Therefore reduce the argument scalars to strings first thing in pp_system.
Fixes [perl #121105].
pod/perldelta.pod
pp_sys.c
t/op/exec.t