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

Side by Side Diff: net/udp/udp_socket_win.cc

Issue 2002713003: QUIC - Pass remote_address_ if address is not specified in UDPSocketWin::Write() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: reverted CL - 1999893002 Created 4 years, 7 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 unified diff | Download patch
« no previous file with comments | « net/quic/quic_stream_factory.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/udp/udp_socket_win.h" 5 #include "net/udp/udp_socket_win.h"
6 6
7 #include <mstcpip.h> 7 #include <mstcpip.h>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 374 matching lines...) Expand 10 before | Expand all | Expand 10 after
385 return nread; 385 return nread;
386 386
387 read_callback_ = callback; 387 read_callback_ = callback;
388 recv_from_address_ = address; 388 recv_from_address_ = address;
389 return ERR_IO_PENDING; 389 return ERR_IO_PENDING;
390 } 390 }
391 391
392 int UDPSocketWin::Write(IOBuffer* buf, 392 int UDPSocketWin::Write(IOBuffer* buf,
393 int buf_len, 393 int buf_len,
394 const CompletionCallback& callback) { 394 const CompletionCallback& callback) {
395 return SendToOrWrite(buf, buf_len, NULL, callback); 395 return SendToOrWrite(buf, buf_len, remote_address_.get(), callback);
396 } 396 }
397 397
398 int UDPSocketWin::SendTo(IOBuffer* buf, 398 int UDPSocketWin::SendTo(IOBuffer* buf,
399 int buf_len, 399 int buf_len,
400 const IPEndPoint& address, 400 const IPEndPoint& address,
401 const CompletionCallback& callback) { 401 const CompletionCallback& callback) {
402 return SendToOrWrite(buf, buf_len, &address, callback); 402 return SendToOrWrite(buf, buf_len, &address, callback);
403 } 403 }
404 404
405 int UDPSocketWin::SendToOrWrite(IOBuffer* buf, 405 int UDPSocketWin::SendToOrWrite(IOBuffer* buf,
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after
1170 void UDPSocketWin::DetachFromThread() { 1170 void UDPSocketWin::DetachFromThread() {
1171 base::NonThreadSafe::DetachFromThread(); 1171 base::NonThreadSafe::DetachFromThread();
1172 } 1172 }
1173 1173
1174 void UDPSocketWin::UseNonBlockingIO() { 1174 void UDPSocketWin::UseNonBlockingIO() {
1175 DCHECK(!core_); 1175 DCHECK(!core_);
1176 use_non_blocking_io_ = true; 1176 use_non_blocking_io_ = true;
1177 } 1177 }
1178 1178
1179 } // namespace net 1179 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_stream_factory.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698