+ //\r
+ // Determine the first thread available to this process.\r
+ //\r
+ if (GetProcessAffinityMask (GetCurrentProcess (), &ProcessAffinityMask, &SystemAffinityMask)) {\r
+ LowBit = (INT32)LowBitSet32 (ProcessAffinityMask);\r
+ if (LowBit != -1) {\r
+ //\r
+ // Force the system to bind the process to a single thread to work\r
+ // around odd semaphore type crashes.\r
+ //\r
+ SetProcessAffinityMask (GetCurrentProcess (), (INTN)(BIT0 << LowBit));\r
+ }\r
+ }\r
+\r