| Index: chrome/browser/chromeos/login/ui/input_events_blocker.cc
|
| diff --git a/chrome/browser/chromeos/login/ui/input_events_blocker.cc b/chrome/browser/chromeos/login/ui/input_events_blocker.cc
|
| index 686c9070fde532f1a4f327d0040f40797effffa8..5207161d0964b16cc310bd65a7fee0c8fe804c16 100644
|
| --- a/chrome/browser/chromeos/login/ui/input_events_blocker.cc
|
| +++ b/chrome/browser/chromeos/login/ui/input_events_blocker.cc
|
| @@ -11,12 +11,14 @@
|
| namespace chromeos {
|
|
|
| InputEventsBlocker::InputEventsBlocker() {
|
| - ash::Shell::GetInstance()->PrependPreTargetHandler(this);
|
| + if (ash::Shell::HasInstance())
|
| + ash::Shell::GetInstance()->PrependPreTargetHandler(this);
|
| VLOG(1) << "InputEventsBlocker " << this << " created.";
|
| }
|
|
|
| InputEventsBlocker::~InputEventsBlocker() {
|
| - ash::Shell::GetInstance()->RemovePreTargetHandler(this);
|
| + if (ash::Shell::HasInstance())
|
| + ash::Shell::GetInstance()->RemovePreTargetHandler(this);
|
| VLOG(1) << "InputEventsBlocker " << this << " destroyed.";
|
| }
|
|
|
|
|