mirror of
https://github.com/ttttupup/wxhelper.git
synced 2025-02-22 16:14:56 +08:00
fix:修正GetPIDForProcess获取不到进程ID的bug
This commit is contained in:
parent
62a641d7f7
commit
1528b66b94
@ -526,7 +526,7 @@ DWORD GetPIDForProcess(wchar_t* process)
|
|||||||
if (!hSnapshot) {
|
if (!hSnapshot) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
pe32.dwSize = sizeof(PROCESSENTRY32);
|
pe32.dwSize = sizeof(PROCESSENTRY32W);
|
||||||
for (working = Process32FirstW(hSnapshot, &pe32); working; working = Process32NextW(hSnapshot, &pe32))
|
for (working = Process32FirstW(hSnapshot, &pe32); working; working = Process32NextW(hSnapshot, &pe32))
|
||||||
{
|
{
|
||||||
if (!wcscmp(pe32.szExeFile, process))
|
if (!wcscmp(pe32.szExeFile, process))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user