summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ash/shelf/shelf_layout_manager.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/ash/shelf/shelf_layout_manager.cc b/ash/shelf/shelf_layout_manager.cc
index 3f22fce..21fb0b3 100644
--- a/ash/shelf/shelf_layout_manager.cc
+++ b/ash/shelf/shelf_layout_manager.cc
@@ -311,6 +311,11 @@ ShelfVisibilityState ShelfLayoutManager::CalculateShelfVisibility() {
}
void ShelfLayoutManager::UpdateVisibilityState() {
+ // Bail out early when there is no |workspace_controller_|, which happens
+ // during shutdown after PrepareForShutdown.
+ if (!workspace_controller_)
+ return;
+
if (Shell::GetInstance()->session_state_delegate()->IsScreenLocked()) {
SetState(SHELF_VISIBLE);
} else {