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

Side by Side Diff: remoting/protocol/channel_multiplexer.cc

Issue 12207034: Linux/ChromeOS Chromium style checker cleanup, remoting/ edition. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « remoting/protocol/buffered_socket_writer_unittest.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 "remoting/protocol/channel_multiplexer.h" 5 #include "remoting/protocol/channel_multiplexer.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 std::list<PendingPacket*> pending_packets_; 97 std::list<PendingPacket*> pending_packets_;
98 98
99 DISALLOW_COPY_AND_ASSIGN(MuxChannel); 99 DISALLOW_COPY_AND_ASSIGN(MuxChannel);
100 }; 100 };
101 101
102 class ChannelMultiplexer::MuxSocket : public net::StreamSocket, 102 class ChannelMultiplexer::MuxSocket : public net::StreamSocket,
103 public base::NonThreadSafe, 103 public base::NonThreadSafe,
104 public base::SupportsWeakPtr<MuxSocket> { 104 public base::SupportsWeakPtr<MuxSocket> {
105 public: 105 public:
106 MuxSocket(MuxChannel* channel); 106 MuxSocket(MuxChannel* channel);
107 ~MuxSocket(); 107 virtual ~MuxSocket();
108 108
109 void OnWriteComplete(); 109 void OnWriteComplete();
110 void OnWriteFailed(); 110 void OnWriteFailed();
111 void OnPacketReceived(); 111 void OnPacketReceived();
112 112
113 // net::StreamSocket interface. 113 // net::StreamSocket interface.
114 virtual int Read(net::IOBuffer* buffer, int buffer_len, 114 virtual int Read(net::IOBuffer* buffer, int buffer_len,
115 const net::CompletionCallback& callback) OVERRIDE; 115 const net::CompletionCallback& callback) OVERRIDE;
116 virtual int Write(net::IOBuffer* buffer, int buffer_len, 116 virtual int Write(net::IOBuffer* buffer, int buffer_len,
117 const net::CompletionCallback& callback) OVERRIDE; 117 const net::CompletionCallback& callback) OVERRIDE;
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after
518 channel->OnIncomingPacket(packet.Pass(), done_task); 518 channel->OnIncomingPacket(packet.Pass(), done_task);
519 } 519 }
520 520
521 bool ChannelMultiplexer::DoWrite(scoped_ptr<MultiplexPacket> packet, 521 bool ChannelMultiplexer::DoWrite(scoped_ptr<MultiplexPacket> packet,
522 const base::Closure& done_task) { 522 const base::Closure& done_task) {
523 return writer_.Write(SerializeAndFrameMessage(*packet), done_task); 523 return writer_.Write(SerializeAndFrameMessage(*packet), done_task);
524 } 524 }
525 525
526 } // namespace protocol 526 } // namespace protocol
527 } // namespace remoting 527 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/buffered_socket_writer_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698