summaryrefslogtreecommitdiff
path: root/ServiceManager.cpp
diff options
context:
space:
mode:
authorSteven Moreland <smoreland@google.com>2021-04-27 18:36:18 +0000
committerSteven Moreland <smoreland@google.com>2021-04-27 18:50:19 +0000
commit465134d658fc32c0ed7ca40d3664b86b48307a1c (patch)
treed7b62023c6f5d585d5bb05edc2ee9bd932ba2eea /ServiceManager.cpp
parent0ef0cd8fffb4d4d7044931bee1d2837c2ee99474 (diff)
downloadhwservicemanager-465134d658fc32c0ed7ca40d3664b86b48307a1c.tar.gz
hwservicemanager: log on failed lazy startandroid-s-beta-2android-s-beta-1
libc and init will both log in this case, but the logs are confusing, so adding a 3rd log where we can share more of a hint for this particular usecase. Bug: N/A Test: boot & force log to happen Change-Id: I9a58c1a6f5309eba07841739b1e8da546199a9b9
Diffstat (limited to 'ServiceManager.cpp')
-rw-r--r--ServiceManager.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/ServiceManager.cpp b/ServiceManager.cpp
index 8db7a1a..283b054 100644
--- a/ServiceManager.cpp
+++ b/ServiceManager.cpp
@@ -255,7 +255,12 @@ static void tryStartService(const std::string& fqName, const std::string& name)
<< " is not registered, trying to start it as a lazy HAL.";
std::thread([=] {
- (void)SetProperty("ctl.interface_start", fqName + "/" + name);
+ if (!SetProperty("ctl.interface_start", fqName + "/" + name)) {
+ LOG(INFO) << "Tried to start " << fqName << "/" << name
+ << " as a lazy service, but was unable to. Usually this happens when a "
+ "service is not installed, but if the service is intended to be used as a "
+ "lazy service, then it may be configured incorrectly.";
+ }
}).detach();
}