Strange return value from os.system(...) call
Michael Fuhr
mfuhr at fuhr.org
Wed Oct 13 00:15:41 EDT 2004
David Scott Williams <xiarcel at optonline.net> writes:
> somevalue=os.system("/path/to/script")
> print "somevalue:"+str(somevalue)
>
> If my script exits with 0, somevalue is 0
> ...if it exits with 1, somevalue is 256
See the documentation for os.system(), os.wait(), and os.WEXITSTATUS():
http://www.python.org/doc/2.3.4/lib/os-process.html
--
Michael Fuhr
http://www.fuhr.org/~mfuhr/
More information about the Python-list
mailing list