mirror of
https://github.com/azahar-emu/azahar.git
synced 2026-06-06 02:33:44 -04:00
Revert "core: Temporary workaround for MSVC compiler bug (#1505)"
This reverts commit b0fe4d190d.
This commit is contained in:
parent
fa3be2d9a5
commit
64b7f7e5b1
2 changed files with 3 additions and 8 deletions
|
|
@ -178,7 +178,7 @@ void ServiceFrameworkBase::ReportUnimplementedFunction(u32* cmd_buf, const Funct
|
|||
void ServiceFrameworkBase::HandleSyncRequest(Kernel::HLERequestContext& context) {
|
||||
auto itr = handlers.find(context.CommandHeader().command_id.Value());
|
||||
const FunctionInfoBase* info = itr == handlers.end() ? nullptr : &itr->second;
|
||||
if (info == nullptr || !info->implemented) {
|
||||
if (info == nullptr || info->handler_callback == nullptr) {
|
||||
context.ReportUnimplemented();
|
||||
return ReportUnimplementedFunction(context.CommandBuffer(), info);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -82,7 +82,6 @@ private:
|
|||
|
||||
struct FunctionInfoBase {
|
||||
u32 command_id;
|
||||
bool implemented;
|
||||
HandlerFnP<ServiceFrameworkBase> handler_callback;
|
||||
const char* name;
|
||||
};
|
||||
|
|
@ -97,8 +96,6 @@ private:
|
|||
void RegisterHandlersBase(const FunctionInfoBase* functions, std::size_t n);
|
||||
void ReportUnimplementedFunction(u32* cmd_buf, const FunctionInfoBase* info);
|
||||
|
||||
void Empty(Kernel::HLERequestContext& ctx) {}
|
||||
|
||||
/// Identifier string used to connect to the service.
|
||||
std::string service_name;
|
||||
/// Maximum number of concurrent sessions that this service can handle.
|
||||
|
|
@ -137,11 +134,9 @@ protected:
|
|||
*/
|
||||
constexpr FunctionInfo(u32 command_id, HandlerFnP<Self> handler_callback, const char* name)
|
||||
: FunctionInfoBase{
|
||||
command_id, handler_callback != nullptr,
|
||||
command_id,
|
||||
// Type-erase member function pointer by casting it down to the base class.
|
||||
handler_callback ? static_cast<HandlerFnP<ServiceFrameworkBase>>(handler_callback)
|
||||
: &ServiceFrameworkBase::Empty,
|
||||
name} {}
|
||||
static_cast<HandlerFnP<ServiceFrameworkBase>>(handler_callback), name} {}
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue