summaryrefslogtreecommitdiff
path: root/cmds/servicemanager/ServiceManager.h
diff options
context:
space:
mode:
author Steven Moreland <smoreland@google.com> 2023-02-01 21:27:52 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2023-02-01 21:27:52 +0000
commitb0c7b608b99e3c089ae2ec4b163183135012b51c (patch)
tree18c4c69993e7ecee3d08cdc942b78c33d0ef664e /cmds/servicemanager/ServiceManager.h
parentba75fbf758e90610799975c7c11e15a85c8e614e (diff)
parente622f3bd6e352cb77d74be0f013cdbadb996cb79 (diff)
Merge "servicemanager: fix lazy service issues" am: 355cafc805 am: b9fa27e706 am: e622f3bd6e
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2404738 Change-Id: I1e472647bd6d707e664b55a2058a43b00088e3ca Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
Diffstat (limited to 'cmds/servicemanager/ServiceManager.h')
-rw-r--r--cmds/servicemanager/ServiceManager.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/cmds/servicemanager/ServiceManager.h b/cmds/servicemanager/ServiceManager.h
index f9d4f8fd90..3aa6731eb3 100644
--- a/cmds/servicemanager/ServiceManager.h
+++ b/cmds/servicemanager/ServiceManager.h
@@ -80,6 +80,8 @@ private:
// the number of clients of the service, including servicemanager itself
ssize_t getNodeStrongRefCount();
+
+ ~Service();
};
using ServiceCallbackMap = std::map<std::string, std::vector<sp<IServiceCallback>>>;
@@ -91,7 +93,9 @@ private:
void removeRegistrationCallback(const wp<IBinder>& who,
ServiceCallbackMap::iterator* it,
bool* found);
- ssize_t handleServiceClientCallback(const std::string& serviceName, bool isCalledOnInterval);
+ // returns whether there are known clients in addition to the count provided
+ bool handleServiceClientCallback(size_t knownClients, const std::string& serviceName,
+ bool isCalledOnInterval);
// Also updates mHasClients (of what the last callback was)
void sendClientCallbackNotifications(const std::string& serviceName, bool hasClients,
const char* context);