OpenSSL  1.0.1c
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros
tlhelp32.h
Go to the documentation of this file.
1 /*
2  tlhelp32.h - Include file for Tool help functions.
3 
4  Written by Mumit Khan <[email protected]>
5 
6  This file is part of a free library for the Win32 API.
7 
8  This library is distributed in the hope that it will be useful,
9  but WITHOUT ANY WARRANTY; without even the implied warranty of
10  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11 
12 */
13 #ifndef _TLHELP32_H
14 #define _TLHELP32_H
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 #define HF32_DEFAULT 1
19 #define HF32_SHARED 2
20 #define LF32_FIXED 0x1
21 #define LF32_FREE 0x2
22 #define LF32_MOVEABLE 0x4
23 #define MAX_MODULE_NAME32 255
24 #define TH32CS_SNAPHEAPLIST 0x1
25 #define TH32CS_SNAPPROCESS 0x2
26 #define TH32CS_SNAPTHREAD 0x4
27 #define TH32CS_SNAPMODULE 0x8
28 #define TH32CS_SNAPALL (TH32CS_SNAPHEAPLIST|TH32CS_SNAPPROCESS|TH32CS_SNAPTHREAD|TH32CS_SNAPMODULE)
29 #define TH32CS_INHERIT 0x80000000
30 typedef struct tagHEAPLIST32 {
31  DWORD dwSize;
33  DWORD th32HeapID;
34  DWORD dwFlags;
36 typedef struct tagHEAPENTRY32 {
37  DWORD dwSize;
38  HANDLE hHandle;
39  DWORD dwAddress;
40  DWORD dwBlockSize;
41  DWORD dwFlags;
42  DWORD dwLockCount;
43  DWORD dwResvd;
45  DWORD th32HeapID;
47 typedef struct tagPROCESSENTRY32W {
48  DWORD dwSize;
49  DWORD cntUsage;
52  DWORD th32ModuleID;
53  DWORD cntThreads;
56  DWORD dwFlags;
57  WCHAR szExeFile[MAX_PATH];
59 typedef struct tagPROCESSENTRY32 {
60  DWORD dwSize;
61  DWORD cntUsage;
64  DWORD th32ModuleID;
65  DWORD cntThreads;
68  DWORD dwFlags;
69  CHAR szExeFile[MAX_PATH];
71 typedef struct tagTHREADENTRY32 {
72  DWORD dwSize;
73  DWORD cntUsage;
74  DWORD th32ThreadID;
76  LONG tpBasePri;
77  LONG tpDeltaPri;
78  DWORD dwFlags;
80 typedef struct tagMODULEENTRY32W {
81  DWORD dwSize;
82  DWORD th32ModuleID;
84  DWORD GlblcntUsage;
85  DWORD ProccntUsage;
86  BYTE *modBaseAddr;
87  DWORD modBaseSize;
88  HMODULE hModule;
90  WCHAR szExePath[MAX_PATH];
92 typedef struct tagMODULEENTRY32 {
93  DWORD dwSize;
94  DWORD th32ModuleID;
96  DWORD GlblcntUsage;
97  DWORD ProccntUsage;
98  BYTE *modBaseAddr;
99  DWORD modBaseSize;
100  HMODULE hModule;
102  char szExePath[MAX_PATH];
104 BOOL WINAPI Heap32First(LPHEAPENTRY32,DWORD,DWORD);
105 BOOL WINAPI Heap32ListFirst(HANDLE,LPHEAPLIST32);
106 BOOL WINAPI Heap32ListNext(HANDLE,LPHEAPLIST32);
107 BOOL WINAPI Heap32Next(LPHEAPENTRY32);
108 BOOL WINAPI Module32First(HANDLE,LPMODULEENTRY32);
109 BOOL WINAPI Module32FirstW(HANDLE,LPMODULEENTRY32W);
110 BOOL WINAPI Module32Next(HANDLE,LPMODULEENTRY32);
111 BOOL WINAPI Module32NextW(HANDLE,LPMODULEENTRY32W);
112 BOOL WINAPI Process32First(HANDLE,LPPROCESSENTRY32);
113 BOOL WINAPI Process32FirstW(HANDLE,LPPROCESSENTRY32W);
114 BOOL WINAPI Process32Next(HANDLE,LPPROCESSENTRY32);
115 BOOL WINAPI Process32NextW(HANDLE,LPPROCESSENTRY32W);
116 BOOL WINAPI Thread32First(HANDLE,LPTHREADENTRY32);
117 BOOL WINAPI Thread32Next(HANDLE,LPTHREADENTRY32);
118 BOOL WINAPI Toolhelp32ReadProcessMemory(DWORD,LPCVOID,LPVOID,DWORD,LPDWORD);
119 HANDLE WINAPI CreateToolhelp32Snapshot(DWORD,DWORD);
120 #ifdef UNICODE
121 #define LPMODULEENTRY32 LPMODULEENTRY32W
122 #define LPPROCESSENTRY32 LPPROCESSENTRY32W
123 #define MODULEENTRY32 MODULEENTRY32W
124 #define Module32First Module32FirstW
125 #define Module32Next Module32NextW
126 #define PMODULEENTRY32 PMODULEENTRY32W
127 #define PPROCESSENTRY32 PPROCESSENTRY32W
128 #define PROCESSENTRY32 PROCESSENTRY32W
129 #define Process32First Process32FirstW
130 #define Process32Next Process32NextW
131 #endif /* UNICODE */
132 #ifdef __cplusplus
133 }
134 #endif
135 #endif /* _TLHELP32_H */
136