mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-14 21:00:42 +02:00
UnixLib: Add a way to get Linux process PID
This commit is contained in:
4 files changed
+27
No files matched your search
@@ -176,6 +176,11 @@ static NTSTATUS FEXUnixLib_MapFileHandler(void* _Args) {
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
static NTSTATUS FEXUnixLib_GetPIDHandler(void* _Args) {
|
||||
auto Args = reinterpret_cast<FEXUnixLib_GetPID*>(_Args);
|
||||
Args->Result = ::getpid();
|
||||
return STATUS_SUCCESS;
|
||||
}
|
||||
extern "C" const unixlib_entry_t __wine_unix_call_funcs[] = {
|
||||
FEXUnixLib_SetHardwareTSOControlHandler,
|
||||
FEXUnixLib_SetKernelUnalignedAtomicControlHandler,
|
||||
@@ -184,6 +189,7 @@ extern "C" const unixlib_entry_t __wine_unix_call_funcs[] = {
|
||||
FEXUnixLib_GetSHMStatsVMAHandler,
|
||||
FEXUnixLib_DeleteSHMStatsFileHandler,
|
||||
FEXUnixLib_MapFileHandler,
|
||||
FEXUnixLib_GetPIDHandler,
|
||||
};
|
||||
|
||||
static_assert(sizeof(__wine_unix_call_funcs) / sizeof(__wine_unix_call_funcs[0]) == ToUnderlying(FEXUnixLibFunctions::MAX));
|
||||
Reference in new issue
Block a user