Fixed sporadically deadlocks/blocks.