[Python-checkins] r47106 - python/trunk/Lib/test/test_mailbox.py

andrew.kuchling python-checkins at python.org
Mon Jun 26 19:00:35 CEST 2006


Author: andrew.kuchling
Date: Mon Jun 26 19:00:35 2006
New Revision: 47106

Modified:
   python/trunk/Lib/test/test_mailbox.py
Log:
Attempt to fix build failure on OS X and Debian alpha; the symptom is
consistent with os.wait() returning immediately because some other
subprocess had previously exited; the test suite then immediately
tries to lock the mailbox and gets an error saying it's already
locked.

To fix this, do a waitpid() so the test suite only continues once 
the intended child process has exited.


Modified: python/trunk/Lib/test/test_mailbox.py
==============================================================================
--- python/trunk/Lib/test/test_mailbox.py	(original)
+++ python/trunk/Lib/test/test_mailbox.py	Mon Jun 26 19:00:35 2006
@@ -740,7 +740,7 @@
                           self._box.lock)
         
         # Wait for child to exit.  Locking should now succeed.
-        pid, status = os.wait()
+        exited_pid, status = os.waitpid(pid, 0)
         self._box.lock()
         self._box.unlock()
         


More information about the Python-checkins mailing list