Index: mojo/edk/system/channel.h |
diff --git a/mojo/edk/system/channel.h b/mojo/edk/system/channel.h |
index 0d7ccdb613f591a8659dad663f3741a628e0a549..54b64121ef9a0c486a4e090eca26559655dd07d5 100644 |
--- a/mojo/edk/system/channel.h |
+++ b/mojo/edk/system/channel.h |
@@ -45,8 +45,8 @@ class Channel : public base::RefCountedThreadSafe<Channel> { |
// Message size in bytes, including the header. |
uint32_t num_bytes; |
-#if defined(OS_CHROMEOS) |
- // Old message wire format for ChromeOS. |
+#if defined(OS_CHROMEOS) || defined(OS_ANDROID) |
+ // Old message wire format for ChromeOS and Android. |
// Number of attached handles. |
uint16_t num_handles; |
@@ -64,7 +64,7 @@ class Channel : public base::RefCountedThreadSafe<Channel> { |
MessageType message_type; |
char padding[6]; |
-#endif // defined(OS_CHROMEOS) |
+#endif // defined(OS_CHROMEOS) || defined(OS_ANDROID) |
}; |
#pragma pack(pop) |
@@ -82,7 +82,7 @@ class Channel : public base::RefCountedThreadSafe<Channel> { |
const void* data() const { return data_; } |
size_t data_num_bytes() const { return size_; } |
-#if defined(OS_CHROMEOS) |
+#if defined(OS_CHROMEOS) || defined(OS_ANDROID) |
void* mutable_payload() { return static_cast<void*>(header_ + 1); } |
const void* payload() const { |
return static_cast<const void*>(header_ + 1); |
@@ -98,7 +98,7 @@ class Channel : public base::RefCountedThreadSafe<Channel> { |
void* mutable_payload() { return data_ + header_->num_header_bytes; } |
const void* payload() const { return data_ + header_->num_header_bytes; } |
size_t payload_size() const; |
-#endif // defined(OS_CHROMEOS) |
+#endif // defined(OS_CHROMEOS) || defined(OS_ANDROID) |
size_t num_handles() const { return header_->num_handles; } |
bool has_handles() const { return header_->num_handles > 0; } |