SenseApiMgr: Provide ComponentThread::getSelf access to libs

This commit is contained in:
2025-09-09 12:02:40 -04:00
parent 725f8772b1
commit 48121ec84c
2 changed files with 17 additions and 1 deletions
+8 -1
View File
@@ -66,12 +66,19 @@ static std::optional<std::string> searchForLibInSmoSearchPaths(
return std::nullopt;
}
/* Local static function to wrap ComponentThread::getSelf for SmoCallbacks */
static std::shared_ptr<ComponentThread> ComponentThread_getSelf()
{
return ComponentThread::getSelf();
}
/* Hooks to be provided to senseApiLibs, enabling them to call into Salmanoff
* code.
*/
static SmoCallbacks smoCallbacks =
{
.searchForLibInSmoSearchPaths = searchForLibInSmoSearchPaths
.searchForLibInSmoSearchPaths = searchForLibInSmoSearchPaths,
.ComponentThread_getSelf = ComponentThread_getSelf
};
/* Static file-scope threading model object for senseApi libraries */