Merge "Fixes 2 race conditions in MetricsLoggerService" into nyc-dev
am: 9710859
* commit '9710859b5102f36499a628f2931bafd0a6803437':
Fixes 2 race conditions in MetricsLoggerService
Change-Id: Ic5dcdfe471c9ee37de2a750b70ee0b78fd2bf5da
This commit is contained in:
@@ -192,11 +192,13 @@ public class MetricsLoggerService extends SystemService {
|
||||
}
|
||||
}
|
||||
|
||||
if (!mPendingIntents.isEmpty()) {
|
||||
pw.println();
|
||||
pw.println("Pending intents:");
|
||||
for (PendingIntent pi : mPendingIntents) {
|
||||
pw.println(pi.toString());
|
||||
synchronized (mPendingIntents) {
|
||||
if (!mPendingIntents.isEmpty()) {
|
||||
pw.println();
|
||||
pw.println("Pending intents:");
|
||||
for (PendingIntent pi : mPendingIntents) {
|
||||
pw.println(pi.toString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -327,9 +329,9 @@ public class MetricsLoggerService extends SystemService {
|
||||
result[i++] = e;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
reference.setValue(mLastEventReference);
|
||||
reference.setValue(mLastEventReference);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user