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

Side by Side Diff: net/spdy/spdy_websocket_stream.cc

Issue 15829004: Update net/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: license twerk Created 7 years, 6 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 | « net/spdy/spdy_test_util_common.cc ('k') | net/spdy/spdy_websocket_stream_spdy2_unittest.cc » ('j') | 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/spdy/spdy_websocket_stream.h" 5 #include "net/spdy/spdy_websocket_stream.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
11 #include "net/base/io_buffer.h" 11 #include "net/base/io_buffer.h"
12 #include "net/base/net_errors.h" 12 #include "net/base/net_errors.h"
13 #include "net/spdy/spdy_framer.h" 13 #include "net/spdy/spdy_framer.h"
14 #include "net/spdy/spdy_protocol.h" 14 #include "net/spdy/spdy_protocol.h"
15 #include "net/spdy/spdy_session.h" 15 #include "net/spdy/spdy_session.h"
16 #include "net/spdy/spdy_stream.h" 16 #include "net/spdy/spdy_stream.h"
17 17
18 namespace net { 18 namespace net {
19 19
20 SpdyWebSocketStream::SpdyWebSocketStream( 20 SpdyWebSocketStream::SpdyWebSocketStream(
21 SpdySession* spdy_session, Delegate* delegate) 21 SpdySession* spdy_session, Delegate* delegate)
22 : weak_ptr_factory_(this), 22 : weak_ptr_factory_(this),
23 spdy_session_(spdy_session), 23 spdy_session_(spdy_session),
24 pending_send_data_length_(0), 24 pending_send_data_length_(0),
25 delegate_(delegate) { 25 delegate_(delegate) {
26 DCHECK(spdy_session_); 26 DCHECK(spdy_session_.get());
27 DCHECK(delegate_); 27 DCHECK(delegate_);
28 } 28 }
29 29
30 SpdyWebSocketStream::~SpdyWebSocketStream() { 30 SpdyWebSocketStream::~SpdyWebSocketStream() {
31 delegate_ = NULL; 31 delegate_ = NULL;
32 Close(); 32 Close();
33 } 33 }
34 34
35 int SpdyWebSocketStream::InitializeStream(const GURL& url, 35 int SpdyWebSocketStream::InitializeStream(const GURL& url,
36 RequestPriority request_priority, 36 RequestPriority request_priority,
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 if (result == OK) { 122 if (result == OK) {
123 stream_ = stream_request_.ReleaseStream(); 123 stream_ = stream_request_.ReleaseStream();
124 DCHECK(stream_); 124 DCHECK(stream_);
125 stream_->SetDelegate(this); 125 stream_->SetDelegate(this);
126 } 126 }
127 DCHECK(delegate_); 127 DCHECK(delegate_);
128 delegate_->OnCreatedSpdyStream(result); 128 delegate_->OnCreatedSpdyStream(result);
129 } 129 }
130 130
131 } // namespace net 131 } // namespace net
OLDNEW
« no previous file with comments | « net/spdy/spdy_test_util_common.cc ('k') | net/spdy/spdy_websocket_stream_spdy2_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698