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

Unified Diff: net/udp/udp_socket_unittest.cc

Issue 2250473007: Move UseNonBlockingIO from a windows-only method (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: socket_host_udp_unittest.cc Created 4 years, 4 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/udp/udp_socket_perftest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/udp/udp_socket_unittest.cc
diff --git a/net/udp/udp_socket_unittest.cc b/net/udp/udp_socket_unittest.cc
index 860b4a3ced41f8983dd7b47d82fcaabf4995d331..2a4e60f5adcc46ef25b4ed27cb09c72803f8c415 100644
--- a/net/udp/udp_socket_unittest.cc
+++ b/net/udp/udp_socket_unittest.cc
@@ -170,10 +170,8 @@ void UDPSocketTest::ConnectTest(bool use_nonblocking_io) {
TestNetLog server_log;
std::unique_ptr<UDPServerSocket> server(
new UDPServerSocket(&server_log, NetLog::Source()));
-#if defined(OS_WIN)
if (use_nonblocking_io)
server->UseNonBlockingIO();
-#endif
server->AllowAddressReuse();
int rv = server->Listen(bind_address);
ASSERT_THAT(rv, IsOk());
@@ -185,10 +183,8 @@ void UDPSocketTest::ConnectTest(bool use_nonblocking_io) {
std::unique_ptr<UDPClientSocket> client(
new UDPClientSocket(DatagramSocket::DEFAULT_BIND, RandIntCallback(),
&client_log, NetLog::Source()));
-#if defined(OS_WIN)
if (use_nonblocking_io)
client->UseNonBlockingIO();
-#endif
rv = client->Connect(server_address);
EXPECT_THAT(rv, IsOk());
« no previous file with comments | « net/udp/udp_socket_perftest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698