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

Unified Diff: components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java

Issue 2518133002: [Cronet] Fix NetworkChangeNotifierTest.testNetworkChangeNotifier part 3 (Closed)
Patch Set: Created 4 years, 1 month 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java
diff --git a/components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java b/components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java
index d311c375f3f8bfb3be042b06fefb70eb7898cb54..9ace3b833a4c7f89323fa9a8ad795ab54b967d86 100644
--- a/components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java
+++ b/components/cronet/android/test/javatests/src/org/chromium/net/NetworkChangeNotifierTest.java
@@ -4,7 +4,7 @@
package org.chromium.net;
-import static android.system.OsConstants.AF_INET;
+import static android.system.OsConstants.AF_INET6;
import static android.system.OsConstants.SOCK_STREAM;
import android.annotation.TargetApi;
@@ -43,7 +43,7 @@ public class NetworkChangeNotifierTest extends CronetTestBase {
// Bind a listening socket to a local port. The socket won't be used to accept any
// connections, but rather to get connection stuck waiting to connect.
- FileDescriptor s = Os.socket(AF_INET, SOCK_STREAM, 0);
+ FileDescriptor s = Os.socket(AF_INET6, SOCK_STREAM, 0);
// Bind to 127.0.0.1 and a random port (indicated by special 0 value).
Os.bind(s, InetAddress.getByAddress(null, new byte[] {127, 0, 0, 1}), 0);
// Set backlog to 0 so connections end up stuck waiting to connect().
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698