am 80810f86: Merge "Fix crash in status bar ticker." into gingerbread

Merge commit '80810f86e93866674f3a4ca61f84887e7717aa63' into gingerbread-plus-aosp

* commit '80810f86e93866674f3a4ca61f84887e7717aa63':
  Fix crash in status bar ticker.
This commit is contained in:
Daniel Sandler
2010-08-16 13:20:19 -07:00
committed by Android Git Automerger

View File

@@ -185,11 +185,11 @@ public abstract class Ticker {
final Segment newSegment = new Segment(n, icon, n.notification.tickerText);
// If there's already a notification schedule for this package and id, remove it.
for (int i=0; i<initialCount; i++) {
for (int i=0; i<mSegments.size(); i++) {
Segment seg = mSegments.get(i);
if (n.id == seg.notification.id && n.pkg.equals(seg.notification.pkg)) {
// just update that one to use this new data instead
mSegments.remove(i);
mSegments.remove(i--); // restart iteration here
}
}