summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotificationLogger.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotificationLogger.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotificationLogger.java
index d2034d7a8564..8d2a63e9b3fa 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotificationLogger.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/logging/NotificationLogger.java
@@ -276,14 +276,16 @@ public class NotificationLogger implements StateListener, CoreStartable {
}
}
- @GuardedBy("mDozingLock")
public void startNotificationLogging() {
if (!mLogging) {
mLogging = true;
if (DEBUG) {
Log.i(TAG, "startNotificationLogging");
}
- boolean lockscreen = mLockscreen != null && mLockscreen;
+ boolean lockscreen;
+ synchronized (mDozingLock) {
+ lockscreen = mLockscreen != null && mLockscreen;
+ }
mNotificationPanelLogger.logPanelShown(lockscreen, getVisibleNotifications());
mListContainer.setChildLocationsChangedListener(this::onChildLocationsChanged);
// Sometimes, the transition from lockscreenOrShadeVisible=false ->