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

Unified Diff: net/spdy/spdy_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, 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/spdy/spdy_session_spdy3_unittest.cc ('k') | net/spdy/spdy_stream_spdy2_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_stream.cc
diff --git a/net/spdy/spdy_stream.cc b/net/spdy/spdy_stream.cc
index bd6760fcc25e7027b073397b2930594a5f4ac5e4..cc4fd2d63a1a8de9894715b52543be36e57b064a 100644
--- a/net/spdy/spdy_stream.cc
+++ b/net/spdy/spdy_stream.cc
@@ -397,9 +397,8 @@ int SpdyStream::OnResponseHeadersReceived(const SpdyHeaderBlock& response) {
// For a request/response stream, we're ready for the response
// headers once we've finished sending the request headers and
// the request body (if we have one).
- if ((io_state_ < STATE_OPEN) ||
- (send_status_ == MORE_DATA_TO_SEND) ||
- pending_send_data_)
+ if ((io_state_ < STATE_OPEN) || (send_status_ == MORE_DATA_TO_SEND) ||
+ pending_send_data_.get())
return ERR_SPDY_PROTOCOL_ERROR;
break;
@@ -596,7 +595,7 @@ int SpdyStream::SendRequestHeaders(scoped_ptr<SpdyHeaderBlock> headers,
CHECK_NE(type_, SPDY_PUSH_STREAM);
CHECK_EQ(send_status_, MORE_DATA_TO_SEND);
CHECK(!request_);
- CHECK(!pending_send_data_);
+ CHECK(!pending_send_data_.get());
CHECK_EQ(io_state_, STATE_NONE);
request_ = headers.Pass();
send_status_ = send_status;
@@ -610,7 +609,7 @@ void SpdyStream::SendData(IOBuffer* data,
CHECK_NE(type_, SPDY_PUSH_STREAM);
CHECK_EQ(send_status_, MORE_DATA_TO_SEND);
CHECK_GE(io_state_, STATE_SEND_REQUEST_HEADERS_COMPLETE);
- CHECK(!pending_send_data_);
+ CHECK(!pending_send_data_.get());
pending_send_data_ = new DrainableIOBuffer(data, length);
send_status_ = send_status;
QueueNextDataFrame();
@@ -946,16 +945,17 @@ void SpdyStream::QueueNextDataFrame() {
// that our stream_id is correct.
DCHECK_GT(io_state_, STATE_SEND_REQUEST_HEADERS_COMPLETE);
CHECK_GT(stream_id_, 0u);
- CHECK(pending_send_data_);
+ CHECK(pending_send_data_.get());
CHECK_GT(pending_send_data_->BytesRemaining(), 0);
SpdyDataFlags flags =
(send_status_ == NO_MORE_DATA_TO_SEND) ?
DATA_FLAG_FIN : DATA_FLAG_NONE;
- scoped_ptr<SpdyBuffer> data_buffer(session_->CreateDataBuffer(
- stream_id_,
- pending_send_data_, pending_send_data_->BytesRemaining(),
- flags));
+ scoped_ptr<SpdyBuffer> data_buffer(
+ session_->CreateDataBuffer(stream_id_,
+ pending_send_data_.get(),
+ pending_send_data_->BytesRemaining(),
+ flags));
// We'll get called again by PossiblyResumeIfSendStalled().
if (!data_buffer)
return;
« no previous file with comments | « net/spdy/spdy_session_spdy3_unittest.cc ('k') | net/spdy/spdy_stream_spdy2_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698