Commit 8378d01f authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Win32: use GetNativeSystemInfo to get the processor count

parent e98d0a82
...@@ -909,12 +909,11 @@ unsigned vlc_timer_getoverrun (vlc_timer_t timer) ...@@ -909,12 +909,11 @@ unsigned vlc_timer_getoverrun (vlc_timer_t timer)
/*** CPU ***/ /*** CPU ***/
unsigned vlc_GetCPUCount (void) unsigned vlc_GetCPUCount (void)
{ {
DWORD_PTR process; SYSTEM_INFO systemInfo;
DWORD_PTR system;
if (GetProcessAffinityMask (GetCurrentProcess(), &process, &system)) GetNativeSystemInfo(&systemInfo);
return popcount (system);
return 1; return systemInfo.dwNumberOfProcessors;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment