Fix hang when stopped with an empty queue, as happens on Grails startup.