From 2526f33df0c387faead0350a5cdb09ba144dea99 Mon Sep 17 00:00:00 2001 From: Vladimir Marko Date: Wed, 11 Sep 2013 11:13:55 +0100 Subject: [PATCH] Don't prevent notification updates in DOS protection. The NotificationManagerService limits the number of notifications per package+user to 50. Once that limit is reached, it will refuse new notifications. However, it was also erroneously refusing updates to existing notifications. Bug: 5821364 (cherry picked from commit d9f4c95b7de877e888d833d192b9ecbf7bd47f81) Change-Id: I9abc455ef3863730f8e42c8eecff4892cdbc7c1c --- .../NotificationManagerService.java | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/services/core/java/com/android/server/notification/NotificationManagerService.java b/services/core/java/com/android/server/notification/NotificationManagerService.java index 90e912d03e600..898c17f82a85f 100644 --- a/services/core/java/com/android/server/notification/NotificationManagerService.java +++ b/services/core/java/com/android/server/notification/NotificationManagerService.java @@ -1968,6 +1968,9 @@ public class NotificationManagerService extends SystemService { for (int i=0; i= MAX_PACKAGE_NOTIFICATIONS) { Slog.e(TAG, "Package has already posted " + count @@ -3003,19 +3006,8 @@ public class NotificationManagerService extends SystemService { final int len = list.size(); for (int i=0; i