Restore the old behaviour of the event loop. Fixes #22.