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