Guard GLib.Cond.wait/wait_until calls against spurious or stolen wakeups
It is possible that a spurious or stolen wakeup could occur. For that reason, waiting on a condition variable should always be in a loop, based on an explicitly-checked predicate.
Fixes #34 (closed)