Chromium Code Reviews
DescriptionCheck embargo status in PlatformNotificationServiceImpl::CheckPermissionOnIOThread
window.Notification.permission directly checks the
HostContentSettingsMap for notification permission. This means that if
the permission is embargoed, it will incorrectly return "default"
instead of "denied".
This CL refactors PermissionDecisionAutoBlocker::GetEmbargoResult to be
a static method that can be called with a HostContentSettingsMap
argument. This allows the PlatformNotificationServiceImpl (which is
running on the IO thread) to check the embargo status of the
notification permission and return the correct value.
The long-term fix here is that PermissionManager::GetPermissionStatus
must be made thread safe so that there is one and only one way to
correctly query permission status from any thread.
BUG=730273
Review-Url: https://codereview.chromium.org/2926773002
Cr-Original-Commit-Position: refs/heads/master@{#477856}
Review-Url: https://codereview.chromium.org/2939923003 .
Cr-Commit-Position: refs/branch-heads/3112@{#348}
Cr-Branched-From: b6460e24cf59f429d69de255538d0fc7a425ccf9-refs/heads/master@{#474897}
Committed: https://chromium.googlesource.com/chromium/src/+/611ba643701ed338a8f7bab4b607b8ef530ee2e8
Patch Set 1 #
Messages
Total messages: 2 (1 generated)
|
|||||||||||||||||||||||||||||||||||||