Small fixes

This commit is contained in:
momo5502
2025-06-07 20:10:36 +02:00
parent f44f3f2bb3
commit 906cec808a
3 changed files with 13 additions and 5 deletions

View File

@@ -18,11 +18,12 @@ namespace
std::unique_ptr<io_device> create_device(const std::u16string_view device)
{
if (device == u"CNG" //
|| device == u"Nsi" //
|| device == u"RasAcd" //
|| device == u"PcwDrv" //
|| device == u"DeviceApi\\CMApi" //
if (device == u"CNG" //
|| device == u"Nsi" //
|| device == u"RasAcd" //
|| device == u"PcwDrv" //
|| device == u"DeviceApi\\CMApi" //
|| device == u"DeviceApi\\CMNotify" //
|| device == u"ConDrv\\Server")
{
return std::make_unique<dummy_device>();

View File

@@ -16,6 +16,7 @@ namespace syscalls
// syscalls/event.cpp:
NTSTATUS handle_NtSetEvent(const syscall_context& c, uint64_t handle, emulator_object<LONG> previous_state);
NTSTATUS handle_NtTraceEvent();
NTSTATUS handle_NtQueryEvent();
NTSTATUS handle_NtClearEvent(const syscall_context& c, handle event_handle);
NTSTATUS handle_NtCreateEvent(const syscall_context& c, emulator_object<handle> event_handle,
ACCESS_MASK desired_access,
@@ -1171,6 +1172,7 @@ void syscall_dispatcher::add_handlers(std::map<std::string, syscall_handler>& ha
add_handler(NtCancelWaitCompletionPacket);
add_handler(NtSetWnfProcessNotificationEvent);
add_handler(NtQuerySecurityObject);
add_handler(NtQueryEvent);
#undef add_handler
}

View File

@@ -39,6 +39,11 @@ namespace syscalls
return STATUS_SUCCESS;
}
NTSTATUS handle_NtQueryEvent()
{
return STATUS_NOT_SUPPORTED;
}
NTSTATUS handle_NtClearEvent(const syscall_context& c, const handle event_handle)
{
auto* e = c.proc.events.get(event_handle);