From 34e40129989e446db7233c9b757d4ebd48af7e75 Mon Sep 17 00:00:00 2001 From: Liam Date: Sat, 9 Dec 2023 11:22:42 -0500 Subject: service: use interface factory in server manager --- src/core/hle/service/sm/sm.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/core/hle/service/sm/sm.h') diff --git a/src/core/hle/service/sm/sm.h b/src/core/hle/service/sm/sm.h index 14bfaf8c2..cf102c339 100644 --- a/src/core/hle/service/sm/sm.h +++ b/src/core/hle/service/sm/sm.h @@ -53,7 +53,8 @@ public: explicit ServiceManager(Kernel::KernelCore& kernel_); ~ServiceManager(); - Result RegisterService(std::string name, u32 max_sessions, SessionRequestHandlerPtr handler); + Result RegisterService(std::string name, u32 max_sessions, + SessionRequestHandlerFactory handler_factory); Result UnregisterService(const std::string& name); Result GetServicePort(Kernel::KPort** out_port, const std::string& name); @@ -64,7 +65,7 @@ public: LOG_DEBUG(Service, "Can't find service: {}", service_name); return nullptr; } - return std::static_pointer_cast(service->second); + return std::static_pointer_cast(service->second()); } void InvokeControlRequest(HLERequestContext& context); @@ -79,7 +80,7 @@ private: /// Map of registered services, retrieved using GetServicePort. std::mutex lock; - std::unordered_map registered_services; + std::unordered_map registered_services; std::unordered_map service_ports; /// Kernel context -- cgit v1.2.3