From 5be092be044c2c1a3ed829b8796078d22648016e Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Fri, 16 Jun 2023 13:37:36 +0200 Subject: added GetProcessId this enables mapping the result of a CreateProc call to an integer pid --- src/zencore/thread.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/zencore/thread.cpp') diff --git a/src/zencore/thread.cpp b/src/zencore/thread.cpp index 52b1e5d4e..67a0878d0 100644 --- a/src/zencore/thread.cpp +++ b/src/zencore/thread.cpp @@ -1095,6 +1095,16 @@ GetCurrentThreadId() #endif } +int +GetProcessId(CreateProcResult ProcId) +{ +#if ZEN_PLATFORM_WINDOWS + return static_cast(::GetProcessId(ProcId)); +#else + return ProcId; +#endif +} + void Sleep(int ms) { -- cgit v1.2.3