Fixes to a potential deadlock with managed objects.