In article <[EMAIL PROTECTED]>,
 Grant Edwards <[EMAIL PROTECTED]> wrote:
...
> According to the current module reference, that's the behavior
> of the os.popen*() functions:
> 
> http://docs.python.org/lib/os-newstreams.html#os-newstreams
> 
> > On UNIX, os.popen is posix.popen, is a simple wrapper around
> > the C library popen.  It always invokes the shell.
> 
> Not according the the docs:
> 
>   Also, for each of these variants, on Unix, cmd may be a
>   sequence, in which case arguments will be passed directly to
>   the program without shell intervention (as with os.spawnv()).
>   If cmd is a string it will be passed to the shell (as with
>   os.system()).
> 
> It's not exactly clear what "these variants" refer to, but I
> read it as referring to all of the the os.popen functions.
> 
> Perhaps it only refers to os.popen[234]?

Right.  The paragraphs seem a little scrambled.  Note
the use of "cmd" instead of "command" as the parameter
is named for popen().  Also note "These methods do not
make it possible to retrieve the return code from the
child processes", after the popen() paragraph above tells
you how to do it (using the better term "exit status".)

Or one may look at the source.

   Donn Cave, [EMAIL PROTECTED]
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to