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

Unified Diff: net/android/network_change_notifier_android.cc

Issue 1416213003: Add DatagramClientSocket::BindToDefaultNetwork(),GetBoundNetwork() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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
« no previous file with comments | « net/android/network_change_notifier_android.h ('k') | net/base/network_change_notifier.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/android/network_change_notifier_android.cc
diff --git a/net/android/network_change_notifier_android.cc b/net/android/network_change_notifier_android.cc
index eac6589a8ef23ce88c33298923c733f61d570806..0654ca7bea79516c4965afbc5da365e41939e6df 100644
--- a/net/android/network_change_notifier_android.cc
+++ b/net/android/network_change_notifier_android.cc
@@ -173,9 +173,14 @@ NetworkChangeNotifierAndroid::GetCurrentNetworkConnectionType(
return delegate_->GetNetworkConnectionType(network);
}
-NetworkChangeNotifier::NetworkHandle
-NetworkChangeNotifierAndroid::GetCurrentDefaultNetwork() const {
- return delegate_->GetCurrentDefaultNetwork();
+int NetworkChangeNotifierAndroid::GetCurrentDefaultNetwork(
+ NetworkChangeNotifier::NetworkHandle* network) const {
+ if (base::android::BuildInfo::GetInstance()->sdk_int() <
+ base::android::SDK_VERSION_LOLLIPOP) {
+ return ERR_NOT_IMPLEMENTED;
+ }
+ *network = delegate_->GetCurrentDefaultNetwork();
+ return OK;
}
void NetworkChangeNotifierAndroid::OnConnectionTypeChanged() {
« no previous file with comments | « net/android/network_change_notifier_android.h ('k') | net/base/network_change_notifier.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698