mozilla/rust — pull request #11204 by alexcrichton (2013-12-30 01:35:27+00:00)
Title: Fix a deadlock in a libgreen test

Turns out when you grab an OS mutex, you need to be careful about when and where
things are scheduled!

I've confirmed that I could fairly reliably get a deadlock (1 in 100 times ish) before this, and I cannot get a deadlock after this (after 1000+ runs).

Closes #11200