summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/components/application_manager/src/mobile_message_handler.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/components/application_manager/src/mobile_message_handler.cc b/src/components/application_manager/src/mobile_message_handler.cc
index a1c8385549..732faf8a58 100644
--- a/src/components/application_manager/src/mobile_message_handler.cc
+++ b/src/components/application_manager/src/mobile_message_handler.cc
@@ -231,8 +231,13 @@ MobileMessageHandler::HandleOutgoingMessageProtocolV2(
dataForSending[offset++] = jsonSize;
memcpy(dataForSending + offset, message->json_message().c_str(), jsonSize);
-
+
+ // Default the service type to RPC Service
+ uint8_t type = 0x07;
+
if (message->has_binary_data()) {
+ // Change the service type to Hybrid Service
+ type = 0x0F;
const std::vector<uint8_t>& binaryData = *(message->binary_data());
uint8_t* currentPointer = dataForSending + offset + jsonSize;
for (uint32_t i = 0; i < binarySize; ++i) {
@@ -244,7 +249,8 @@ MobileMessageHandler::HandleOutgoingMessageProtocolV2(
new protocol_handler::RawMessage(message->connection_key(),
message->protocol_version(),
dataForSending,
- dataForSendingSize);
+ dataForSendingSize,
+ type);
delete [] dataForSending;