Fix a deadlock.