use GetCurrentProcessId on Windows

matches what is done elsewhere

Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
Rosen Penev 2023-02-23 19:31:14 -08:00
parent 839c03fe37
commit 55d16ac76b

View File

@ -1676,8 +1676,7 @@ std::string temporaryPath() {
auto guard = std::scoped_lock(cs);
#if defined(_WIN32)
HANDLE process = nullptr;
DWORD pid = ::GetProcessId(process);
DWORD pid = ::GetCurrentProcessId();
#else
pid_t pid = ::getpid();
#endif