[Notifications] Fix crash in AddNotification.
Calling ResetRepositionSession during UpdateNotificationSize can end up deleting notification items. This caused two crashes. One in AddNotification, which calls onItemUpdated, which, without this change, can set item_ to null. The other is a crash in ShouldUpdateControlButtonsColor which does not check if item_ is null since it is called from a context where item_ should not be null. BUG=714493 BUG=714032 Review-Url: https://codereview.chromium.org/2833403002 Cr-Commit-Position: refs/heads/master@{#466914}
Showing
Please register or sign in to comment