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

Unified Diff: net/udp/udp_socket_win.cc

Issue 2453873004: Simplify if condition in UDPSocket::RandomBind (Closed)
Patch Set: Created 4 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/udp/udp_socket_posix.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_win.cc
diff --git a/net/udp/udp_socket_win.cc b/net/udp/udp_socket_win.cc
index 52e41bdfbf2ad09bf6c90cff8dd89eab1d3ef4e1..2f759d834594ef82b7bc1055e76ceae17b7b5689 100644
--- a/net/udp/udp_socket_win.cc
+++ b/net/udp/udp_socket_win.cc
@@ -981,7 +981,7 @@ int UDPSocketWin::RandomBind(const IPAddress& address) {
for (int i = 0; i < kBindRetries; ++i) {
int rv = DoBind(IPEndPoint(address, static_cast<uint16_t>(rand_int_cb_.Run(
kPortStart, kPortEnd))));
- if (rv == OK || rv != ERR_ADDRESS_IN_USE)
+ if (rv != ERR_ADDRESS_IN_USE)
return rv;
}
return DoBind(IPEndPoint(address, 0));
« no previous file with comments | « net/udp/udp_socket_posix.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698