summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorstevenwinfield <steven.winfield@cantabcapital.com>2015-08-21 13:17:13 +0100
committerstevenwinfield <steven.winfield@cantabcapital.com>2015-08-21 13:17:13 +0100
commite251555084b9837a7e813255c1c55632e4274e3e (patch)
treea0a42bc807af4102c93796741ff67d9ec2d677d8
parent3e5aa8a7646cbe31c88413df51c04c06864e25bf (diff)
downloadpsutil-e251555084b9837a7e813255c1c55632e4274e3e.tar.gz
Prevent enum clash when using Windows SDK v8.0
ProcessDebugPort and ProcessImageFileName are defined in PROCESSINFOCLASS in winternl.h - use the same workaround as ProcessBasicInformation, with underscores and #defines.
-rw-r--r--psutil/arch/windows/ntextapi.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/psutil/arch/windows/ntextapi.h b/psutil/arch/windows/ntextapi.h
index d10432a3..7f86c57a 100644
--- a/psutil/arch/windows/ntextapi.h
+++ b/psutil/arch/windows/ntextapi.h
@@ -186,7 +186,7 @@ typedef enum _PROCESSINFOCLASS2 {
ProcessTimes,
ProcessBasePriority,
ProcessRaisePriority,
- ProcessDebugPort,
+ _ProcessDebugPort,
ProcessExceptionPort,
ProcessAccessToken,
ProcessLdtInformation,
@@ -207,7 +207,7 @@ typedef enum _PROCESSINFOCLASS2 {
ProcessForegroundInformation,
_ProcessWow64Information,
/* added after XP+ */
- ProcessImageFileName,
+ _ProcessImageFileName,
ProcessLUIDDeviceMapsEnabled,
ProcessBreakOnTermination,
ProcessDebugObjectHandle,
@@ -224,5 +224,7 @@ typedef enum _PROCESSINFOCLASS2 {
#define PROCESSINFOCLASS PROCESSINFOCLASS2
#define ProcessBasicInformation _ProcessBasicInformation
#define ProcessWow64Information _ProcessWow64Information
+#define ProcessDebugPort _ProcessDebugPort
+#define ProcessImageFileName _ProcessImageFileName
#endif // __NTEXTAPI_H__