commit | de22f8acdc8e3adf94a9770b867b355e3ca88f62 | [log] [tgz] |
---|---|---|
author | Chris Thornton <thorntonc@google.com> | Tue Aug 29 16:46:37 2017 -0700 |
committer | Chris Thornton <thorntonc@google.com> | Wed Aug 30 15:53:37 2017 -0700 |
tree | 2e8cd7f543888c4d51d9abdd86aa0e86c11e69a3 | |
parent | aba0e98b085cc613003bf42dbfe1ad0a3bb2348e [diff] |
If stopAllRecognitions is supported, do not call stopRecognition again. Bug: 65174683 Test: NA Change-Id: I2c179a64d4f14d0c97bc908ad83c0d964217adfd
diff --git a/services/soundtrigger/SoundTriggerHwService.cpp b/services/soundtrigger/SoundTriggerHwService.cpp index 8891aba..952acd7 100644 --- a/services/soundtrigger/SoundTriggerHwService.cpp +++ b/services/soundtrigger/SoundTriggerHwService.cpp
@@ -840,7 +840,7 @@ } const bool supports_stop_all = - (mHalInterface != 0) && (mHalInterface->stopAllRecognitions() == ENOSYS); + (mHalInterface != 0) && (mHalInterface->stopAllRecognitions() != -ENOSYS); for (size_t i = 0; i < mModels.size(); i++) { sp<Model> model = mModels.valueAt(i);