diff options
| -rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/phone/RotationContextButton.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/RotationContextButton.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/RotationContextButton.java index f1460a62903d..b117dec44cb4 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/RotationContextButton.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/RotationContextButton.java @@ -66,7 +66,9 @@ public class RotationContextButton extends ContextualButton implements @Override public void onDestroy() { - mRotationButtonController.cleanUp(); + if (mRotationButtonController != null) { + mRotationButtonController.cleanUp(); + } } @Override |