Fixed handling of events during shutdown, an NPE in BlockPlacementHandler, and some incorrect UnsafeValues behavior.