sbt <shibt...@gmail.com> added the comment: > Also, what is the rationale for the following change: > > - elif timeout == 0.0: > + elif timeout == 0.0 and nleft != 0: > return False
If PeekNamedPipe() returns (navail, nleft) there are 3 cases: 1) navail > 0: just return True 2) navail = nleft = 0: either pipe is empty or next message is empty so fall through to slow path to find out which. 3) navail = 0, nleft > 0: a non-empty message is coming, but nothing is available yet. The check is a shortcut for case 3, although it probably never occurs. I've removed that check in the new patch, and added the unit tests to test_multiprocessing. > There is infrastructure in _multiprocessing to handle Ctrl-C. Look > for "sigint_event" in Modules/_multiprocessing/*. This could be > the topic of a separate issue and patch. I will look in to it. ---------- Added file: http://bugs.python.org/file22366/pipe_poll_2.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue12328> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com