Message220843
The documentation for the WNOHANG flag (https://docs.python.org/3.4/library/os.html#os.WNOHANG) suggests that a return value of (0, 0) indicates success. This is not always true, the second value may contain a value even on success. On OpenBSD 5.5 this is an exaple status of a process that is still running:
pid, status = os.waitpid(pid, os.WNOHANG)
(0, -168927460)
It would be more accurate to say that if pid==0 then the process is running and that status is platform dependent. |
|
Date |
User |
Action |
Args |
2014-06-17 16:23:08 | eradman | set | recipients:
+ eradman, docs@python |
2014-06-17 16:23:08 | eradman | set | messageid: <1403022188.82.0.702725813338.issue21791@psf.upfronthosting.co.za> |
2014-06-17 16:23:08 | eradman | link | issue21791 messages |
2014-06-17 16:23:08 | eradman | create | |
|