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

Unified Diff: webrtc/base/network.cc

Issue 1592763003: fix bug 5430 (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Fix ipv6 test failure. Created 4 years, 11 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 | « no previous file | webrtc/base/network_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/base/network.cc
diff --git a/webrtc/base/network.cc b/webrtc/base/network.cc
index 488c475137a2ee8d7ddbea1fa2ace59175cc3f36..0f13d07548c62d48d2577415ed1a65dfcce96ecb 100644
--- a/webrtc/base/network.cc
+++ b/webrtc/base/network.cc
@@ -771,12 +771,14 @@ IPAddress BasicNetworkManager::QueryDefaultLocalAddress(int family) const {
scoped_ptr<AsyncSocket> socket(
thread_->socketserver()->CreateAsyncSocket(family, SOCK_DGRAM));
if (!socket) {
+ LOG_ERR(LERROR) << "Socket creation failed";
return IPAddress();
}
- if (!socket->Connect(
- SocketAddress(family == AF_INET ? kPublicIPv4Host : kPublicIPv6Host,
- kPublicPort))) {
+ if (socket->Connect(SocketAddress(
+ family == AF_INET ? kPublicIPv4Host : kPublicIPv6Host, kPublicPort)) <
+ 0) {
+ LOG_ERR(LERROR) << "Connect failed with " << socket->GetError();
return IPAddress();
}
return socket->GetLocalAddress().ipaddr();
« no previous file with comments | « no previous file | webrtc/base/network_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698