[issue6689] subprocess doesn't pass arguments correctly on Linux when shell=True
David Fraser
report at bugs.python.org
Fri Aug 14 10:21:04 CEST 2009
David Fraser <davidf at sjsoft.com> added the comment:
Ah, upon closer inspection - the special parameters $0 $1 $2 etc
mentioned in the sh docs refer to parameters within the command string,
so that:
sh -c 'echo $2 $0 $1' run for "the people"
produces:
the people run for
So the correct patch would be to leave out the extra parameters and just
have the quoted string...
The question then becomes, is simple " ".join(args) sufficient or should
there be some quoting of them... attaching a patch in the meantime
although that needs to be resolved.
----------
Added file: http://bugs.python.org/file14718/subprocess-shell-args-2.6.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6689>
_______________________________________
More information about the Python-bugs-list
mailing list