summaryrefslogtreecommitdiff
path: root/libavcodec/pthread.c
diff options
context:
space:
mode:
authorJanne Grunau <janne-libav@jannau.net>2011-12-24 00:04:16 +0100
committerJanne Grunau <janne-libav@jannau.net>2011-12-31 17:40:12 +0100
commit937ff3a18a637a28e56752b57b6c2f6ed47b04c1 (patch)
treeb4428547c9f36f11e8ee7512e671cdf407dd32b9 /libavcodec/pthread.c
parente4e30256f87f177decf59b59e923d05ef64147df (diff)
threads: always include necessary headers for number of CPUs detection
Since the conditions for the actual usage are more specific a less preferred method can be used. This would cause compilation errors because necessary headers are not included.
Diffstat (limited to 'libavcodec/pthread.c')
-rw-r--r--libavcodec/pthread.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/pthread.c b/libavcodec/pthread.c
index 4356b32192..73d96fca1a 100644
--- a/libavcodec/pthread.c
+++ b/libavcodec/pthread.c
@@ -34,9 +34,11 @@
#if HAVE_SCHED_GETAFFINITY
#define _GNU_SOURCE
#include <sched.h>
-#elif HAVE_GETSYSTEMINFO
+#endif
+#if HAVE_GETSYSTEMINFO
#include <windows.h>
-#elif HAVE_SYSCTL
+#endif
+#if HAVE_SYSCTL
#if HAVE_SYS_PARAM_H
#include <sys/param.h>
#endif