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

Unified Diff: net/spdy/spdy_stream.cc

Issue 1459973003: Remove ScopedVector from spdy_stream (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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_stream.h ('k') | no next file » | 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 637f6dbc29b31bebd8f8ea28565501762e6f90d5..551ad6dd0770cf31a76a14feb000cd761fc80c06 100644
--- a/net/spdy/spdy_stream.cc
+++ b/net/spdy/spdy_stream.cc
@@ -178,8 +178,8 @@ void SpdyStream::PushedStreamReplay() {
while (!pending_recv_data_.empty()) {
// Take ownership of the first element of |pending_recv_data_|.
- scoped_ptr<SpdyBuffer> buffer(pending_recv_data_.front());
- pending_recv_data_.weak_erase(pending_recv_data_.begin());
+ scoped_ptr<SpdyBuffer> buffer = std::move(pending_recv_data_.at(0));
+ pending_recv_data_.erase(pending_recv_data_.begin());
bool eof = (buffer == NULL);
@@ -484,7 +484,7 @@ void SpdyStream::OnDataReceived(scoped_ptr<SpdyBuffer> buffer) {
// It should be valid for this to happen in the server push case.
// We'll return received data when delegate gets attached to the stream.
if (buffer) {
- pending_recv_data_.push_back(buffer.Pass());
+ pending_recv_data_.push_back(std::move(buffer));
} else {
pending_recv_data_.push_back(NULL);
// Note: we leave the stream open in the session until the stream
« no previous file with comments | « net/spdy/spdy_stream.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698