Merge change 10328

* changes:
  Prevent IndexOutOfBoundsException on toString() if vibrate array is empty (non null) example: notification.vibrate = new long[0];
This commit is contained in:
Android Code Review
2009-06-10 13:28:56 -07:00

View File

@@ -460,7 +460,9 @@ public class Notification implements Parcelable
sb.append(this.vibrate[i]);
sb.append(',');
}
sb.append(this.vibrate[N]);
if (N != -1) {
sb.append(this.vibrate[N]);
}
sb.append("]");
} else if ((this.defaults & DEFAULT_VIBRATE) != 0) {
sb.append("default");