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

Unified Diff: remoting/protocol/fake_session.h

Issue 10703159: Fix MessageReader to handle errors properly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 | « no previous file | remoting/protocol/fake_session.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/fake_session.h
diff --git a/remoting/protocol/fake_session.h b/remoting/protocol/fake_session.h
index 0ce5eab76d24b7dfdc49c7e31bf5e3aedd3a5594..4000cbc7094c5ff5bbf58b9a9dc14eb94a788f3d 100644
--- a/remoting/protocol/fake_session.h
+++ b/remoting/protocol/fake_session.h
@@ -40,6 +40,7 @@ class FakeSocket : public net::StreamSocket {
const std::string& written_data() const { return written_data_; }
+ void set_next_read_error(int error) { next_read_error_ = error; }
void AppendInputData(const std::vector<char>& data);
void PairWith(FakeSocket* peer_socket);
int input_pos() const { return input_pos_; }
@@ -71,6 +72,7 @@ class FakeSocket : public net::StreamSocket {
virtual net::NextProto GetNegotiatedProtocol() const OVERRIDE;
private:
+ int next_read_error_;
bool read_pending_;
scoped_refptr<net::IOBuffer> read_buffer_;
int read_buffer_size_;
« no previous file with comments | « no previous file | remoting/protocol/fake_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698