ref: d0086b1940c63df724a4bb609b6cab32c2e66b95
parent: 65fa5d2a37b089daed47cb625dbefbd981fea9b0
author: Martin Storsjö <martin@martin.st>
date: Sat Dec 28 16:18:11 EST 2013
Use the right data type for process affinity mask This allows using the same code on 64 bit windows as well. Tested on MSVC 2008-2013.
--- a/codec/console/enc/src/welsenc.cpp
+++ b/codec/console/enc/src/welsenc.cpp
@@ -1207,9 +1207,9 @@
// Merge from Heifei's Wonder. Lock process to a single core
void LockToSingleCore() {
-#if defined(WIN32) && !defined(WIN64)
+#if defined(WIN32)
//for 2005 compiler, change "DWORD" to "DWORD_PTR"
- DWORD ProcessAffMask = 0, SystemAffMask = 0;
+ ULONG_PTR ProcessAffMask = 0, SystemAffMask = 0;
HANDLE hProcess = GetCurrentProcess();
GetProcessAffinityMask (hProcess, &ProcessAffMask, &SystemAffMask);