summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@localhost>2020-09-08 01:10:38 -0700
committerLinux Build Service Account <lnxbuild@localhost>2020-09-08 01:10:38 -0700
commitcd437dece2dc752d7f016b1b007ee6d31771eba6 (patch)
treeec6c213f94360a96dff8eed54f48a02ba8b50bbc
parentbe15588fdf47c814812511019db331e8efdf7758 (diff)
parent9e5f7876e2b01a9e6208a63d8cf5209f6d614d7b (diff)
Merge 9e5f7876e2b01a9e6208a63d8cf5209f6d614d7b on remote branch
Change-Id: Ib63f12885b779f76c0ff04cd8ac450fd2b542f27
-rw-r--r--lights/main.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lights/main.cpp b/lights/main.cpp
index 5bab50d..95cb6d8 100644
--- a/lights/main.cpp
+++ b/lights/main.cpp
@@ -24,6 +24,9 @@ using ::aidl::android::hardware::light::Lights;
int main() {
ABinderProcess_setThreadPoolMaxThreadCount(0);
std::shared_ptr<Lights> lights = ndk::SharedRefBase::make<Lights>();
+ if (!lights) {
+ return EXIT_FAILURE;
+ }
const std::string instance = std::string() + Lights::descriptor + "/default";
binder_status_t status = AServiceManager_addService(lights->asBinder().get(), instance.c_str());