Index: content/browser/geolocation/core_location_provider_mac.mm |
diff --git a/content/browser/geolocation/core_location_provider_mac.mm b/content/browser/geolocation/core_location_provider_mac.mm |
index 826a42f36fb533431db847557f01fd085237f011..fa6fe1fd95539b126ba4ca09a5ed202ee90e93e4 100644 |
--- a/content/browser/geolocation/core_location_provider_mac.mm |
+++ b/content/browser/geolocation/core_location_provider_mac.mm |
@@ -36,17 +36,18 @@ void CoreLocationProviderMac::StopProvider() { |
is_updating_ = false; |
} |
-void CoreLocationProviderMac::GetPosition(Geoposition* position) { |
+void CoreLocationProviderMac::GetPosition(content::Geoposition* position) { |
DCHECK(position); |
*position = position_; |
- DCHECK(position->IsInitialized()); |
+ DCHECK(position->Validate() || |
+ position->error_code != content::Geoposition::ERROR_CODE_NONE); |
} |
-void CoreLocationProviderMac::SetPosition(Geoposition* position) { |
+void CoreLocationProviderMac::SetPosition(content::Geoposition* position) { |
DCHECK(position); |
position_ = *position; |
- DCHECK(position->IsInitialized()); |
- |
+ DCHECK(position->Validate() || |
+ position->error_code != content::Geoposition::ERROR_CODE_NONE); |
UpdateListeners(); |
} |