summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBen Fennema <fennema@google.com>2018-11-30 20:14:57 -0800
committerandroid-build-merger <android-build-merger@google.com>2018-11-30 20:14:57 -0800
commit7b16be1845f4daccb39faac18cc0abaf54886fce (patch)
tree73e65eb0a37bb976ca2e6b5f86d4cadc37f112ac
parente1cc59d443634b69daf53f2fa8210d25d2041e21 (diff)
parent7bf6a0cf68754a8d4f97f3adc54fb51e6cbdd290 (diff)
downloaddevice_google_contexthub-7b16be1845f4daccb39faac18cc0abaf54886fce.tar.gz
device_google_contexthub-7b16be1845f4daccb39faac18cc0abaf54886fce.tar.bz2
device_google_contexthub-7b16be1845f4daccb39faac18cc0abaf54886fce.zip
contexthubhal: fix result when hal doesn't send mgmt message to nanohub
am: 7bf6a0cf68 Change-Id: I4f36db296c4e15a9e5b6d77cd62f85442cd492c1
-rw-r--r--contexthubhal/system_comms.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/contexthubhal/system_comms.cpp b/contexthubhal/system_comms.cpp
index 6edd0cbc..358e2f54 100644
--- a/contexthubhal/system_comms.cpp
+++ b/contexthubhal/system_comms.cpp
@@ -418,7 +418,7 @@ int SystemComm::AppMgmtSession::setup(const hub_message_t *appMsg, uint32_t tran
int SystemComm::AppMgmtSession::setupMgmt(const hub_message_t *appMsg, uint32_t transactionId, uint32_t cmd, AppManager &appManager)
{
- int32_t result = 0;
+ int32_t result = -1; // results are only directly returned on failure
const hub_app_name_t &appName = *static_cast<const hub_app_name_t*>(appMsg->message);
if (appMsg->message_len != sizeof(appName)) {
return -EINVAL;