diff options
Diffstat (limited to 'plugins/ConnectionNotify/src/pid2name.cpp')
| -rw-r--r-- | plugins/ConnectionNotify/src/pid2name.cpp | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/plugins/ConnectionNotify/src/pid2name.cpp b/plugins/ConnectionNotify/src/pid2name.cpp deleted file mode 100644 index 65270e6b00..0000000000 --- a/plugins/ConnectionNotify/src/pid2name.cpp +++ /dev/null @@ -1,21 +0,0 @@ -#include "stdafx.h"
-
-void pid2name(DWORD procid, wchar_t *buffer, size_t bufLen)
-{
- PROCESSENTRY32 ProcessStruct;
- ProcessStruct.dwSize = sizeof(PROCESSENTRY32);
- HANDLE hSnap = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, 0);
- if (hSnap == INVALID_HANDLE_VALUE)
- return;
- if (Process32First(hSnap, &ProcessStruct) == FALSE)
- return;
-
- do {
- if (ProcessStruct.th32ProcessID == procid) {
- wcsncpy_s(buffer, bufLen, ProcessStruct.szExeFile, _TRUNCATE);
- break;
- }
- } while (Process32Next(hSnap, &ProcessStruct));
-
- CloseHandle(hSnap);
-}
|
