]> granicus.if.org Git - python/commitdiff
Remove outdated comment
authorTim Golden <mail@timgolden.me.uk>
Mon, 11 Nov 2013 15:08:40 +0000 (15:08 +0000)
committerTim Golden <mail@timgolden.me.uk>
Mon, 11 Nov 2013 15:08:40 +0000 (15:08 +0000)
1  2 
Lib/subprocess.py

index 15d95bd2c686858c4e4e615cd95b4d783f02e0fa,c3a278836c19121319363f1c896e528b48968202..88355ada1b4dda78c75600b3a9721c5857bb21ad
@@@ -691,18 -662,15 +691,17 @@@ def list2cmdline(seq)
  
  # Various tools for executing commands and looking at their output and status.
  #
- # NB This only works (and is only relevant) for POSIX.
  
  def getstatusoutput(cmd):
 -    """Return (status, output) of executing cmd in a shell.
 +    """    Return (status, output) of executing cmd in a shell.
 +
 +    Execute the string 'cmd' in a shell with 'check_output' and
 +    return a 2-tuple (status, output). Universal newlines mode is used,
 +    meaning that the result with be decoded to a string.
  
 -    Execute the string 'cmd' in a shell with os.popen() and return a 2-tuple
 -    (status, output).  cmd is actually run as '{ cmd ; } 2>&1', so that the
 -    returned output will contain output or error messages.  A trailing newline
 -    is stripped from the output.  The exit status for the command can be
 -    interpreted according to the rules for the C function wait().  Example:
 +    A trailing newline is stripped from the output.
 +    The exit status for the command can be interpreted
 +    according to the rules for the function 'wait'. Example:
  
      >>> import subprocess
      >>> subprocess.getstatusoutput('ls /bin/ls')