mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-24 04:01:05 +00:00
Made g_stub_service a SharedPtr.
This commit is contained in:
parent
e1008c862d
commit
06a89ca9b1
@ -58,7 +58,7 @@ namespace Service {
|
||||
std::unordered_map<std::string, Kernel::SharedPtr<Interface>> g_kernel_named_ports;
|
||||
std::unordered_map<std::string, Kernel::SharedPtr<Interface>> g_srv_services;
|
||||
|
||||
Interface g_stub_service;
|
||||
Kernel::SharedPtr<Interface> g_stub_service;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Module interface
|
||||
@ -73,6 +73,8 @@ static void AddService(Interface* interface) {
|
||||
|
||||
/// Initialize ServiceManager
|
||||
void Init() {
|
||||
g_stub_service = new Interface;
|
||||
|
||||
AddNamedPort(new SRV::Interface);
|
||||
AddNamedPort(new ERR_F::Interface);
|
||||
|
||||
|
@ -120,6 +120,6 @@ extern std::unordered_map<std::string, Kernel::SharedPtr<Interface>> g_kernel_na
|
||||
/// Map of services registered with the "srv:" service, retrieved using GetServiceHandle.
|
||||
extern std::unordered_map<std::string, Kernel::SharedPtr<Interface>> g_srv_services;
|
||||
/// Returned to callers when the requested service is not yet implemented
|
||||
extern Interface g_stub_service;
|
||||
extern Kernel::SharedPtr<Interface> g_stub_service;
|
||||
|
||||
} // namespace
|
||||
|
@ -47,7 +47,7 @@ static void GetServiceHandle(Service::Interface* self) {
|
||||
UNIMPLEMENTED();
|
||||
|
||||
// Return the stubbed (empty) service so that applications can continue
|
||||
cmd_buff[3] = Kernel::g_handle_table.Create(&Service::g_stub_service).MoveFrom();
|
||||
cmd_buff[3] = Kernel::g_handle_table.Create(Service::g_stub_service).MoveFrom();
|
||||
}
|
||||
|
||||
cmd_buff[1] = res.raw;
|
||||
|
Loading…
Reference in New Issue
Block a user