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

Unified Diff: components/proximity_auth/connection.h

Issue 562763004: [EasyUnlock] Port PermitMessage class to native code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Left-shift by zero bits for parallelism Created 6 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 | « components/proximity_auth/BUILD.gn ('k') | components/proximity_auth/connection.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/proximity_auth/connection.h
diff --git a/components/proximity_auth/connection.h b/components/proximity_auth/connection.h
index b904f84ee5bc60448361a4d935cdd4e7c4ffce35..b0275da60d7087964141f04b8f13f48a5a78787b 100644
--- a/components/proximity_auth/connection.h
+++ b/components/proximity_auth/connection.h
@@ -75,13 +75,13 @@ class Connection {
// in progress.
virtual void SendMessageImpl(scoped_ptr<WireMessage> message) = 0;
- // Returns |true| iff the |received_bytes_| are long enough to contain a
- // complete wire message. Exposed for testing.
- virtual bool HasReceivedCompleteMessage();
-
// Deserializes the |recieved_bytes_| and returns the resulting WireMessage,
- // or NULL if the message is malformed. Exposed for testing.
- virtual scoped_ptr<WireMessage> DeserializeWireMessage();
+ // or NULL if the message is malformed. Sets |is_incomplete_message| to true
+ // if the |serialized_message| does not have enough data to parse the header,
+ // or if the message length encoded in the message header exceeds the size of
+ // the |serialized_message|. Exposed for testing.
+ virtual scoped_ptr<WireMessage> DeserializeWireMessage(
+ bool* is_incomplete_message);
private:
// The remote device corresponding to this connection.
« no previous file with comments | « components/proximity_auth/BUILD.gn ('k') | components/proximity_auth/connection.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698