Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(649)

Unified Diff: third_party/WebKit/Source/modules/geolocation/Geolocation.cpp

Issue 2049003002: Wrap GCed raw pointer parameters of WTF::bind with Persistent (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
diff --git a/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp b/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
index 933bcea61d8dbc3721c823af526d30656117e8b6..7912642e501e12e987249dde9f85b49503772f25 100644
--- a/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
+++ b/third_party/WebKit/Source/modules/geolocation/Geolocation.cpp
@@ -430,7 +430,7 @@ void Geolocation::requestPermission()
mojom::blink::PermissionName::GEOLOCATION,
getExecutionContext()->getSecurityOrigin()->toString(),
UserGestureIndicator::processingUserGesture(),
- createBaseCallback(bind(&Geolocation::onGeolocationPermissionUpdated, this)));
+ createBaseCallback(bind(&Geolocation::onGeolocationPermissionUpdated, wrapPersistent(this))));
}
void Geolocation::makeSuccessCallbacks()
@@ -503,7 +503,7 @@ void Geolocation::updateGeolocationServiceConnection()
void Geolocation::queryNextPosition()
{
- m_geolocationService->QueryNextPosition(createBaseCallback(bind(&Geolocation::onPositionUpdated, this)));
+ m_geolocationService->QueryNextPosition(createBaseCallback(bind(&Geolocation::onPositionUpdated, wrapPersistent(this))));
}
void Geolocation::onPositionUpdated(mojom::blink::GeopositionPtr position)

Powered by Google App Engine
This is Rietveld 408576698