]> granicus.if.org Git - python/commitdiff
Attempt to fix build failure on OS X and Debian alpha; the symptom is
authorAndrew M. Kuchling <amk@amk.ca>
Mon, 26 Jun 2006 17:00:35 +0000 (17:00 +0000)
committerAndrew M. Kuchling <amk@amk.ca>
Mon, 26 Jun 2006 17:00:35 +0000 (17:00 +0000)
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.

Lib/test/test_mailbox.py

index b00496ca4f70810d559969c5b48e447323b1e3c9..e17de5dfdd017b05c35393b4d301cbc8cdf362a4 100644 (file)
@@ -740,7 +740,7 @@ class _TestMboxMMDF(TestMailbox):
                           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()