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

Unified Diff: net/flip/flip_session.cc

Issue 208042: Fixup the flip buffer to use a regular IOBuffer... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 3 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/flip/flip_session.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/flip/flip_session.cc
===================================================================
--- net/flip/flip_session.cc (revision 26596)
+++ net/flip/flip_session.cc (working copy)
@@ -96,8 +96,7 @@
connection_started_(false),
delayed_write_pending_(false),
write_pending_(false),
- read_buffer_(new net::MovableIOBuffer(kReadBufferSize)),
- read_buffer_bytes_read_(0),
+ read_buffer_(new IOBuffer(kReadBufferSize)),
read_pending_(false),
stream_hi_water_mark_(0) {
// Always start at 1 for the first stream id.
@@ -365,10 +364,8 @@
if (read_pending_)
return;
- size_t max_bytes = kReadBufferSize;
- read_buffer_->set_data(read_buffer_bytes_read_);
- max_bytes -= read_buffer_bytes_read_;
- int bytes_read = connection_.socket()->Read(read_buffer_.get(), max_bytes,
+ int bytes_read = connection_.socket()->Read(read_buffer_.get(),
+ kReadBufferSize,
&read_callback_);
switch (bytes_read) {
case 0:
« no previous file with comments | « net/flip/flip_session.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698