From 3b41e626668ed22d4267f7e79193d852b4d1edd1 Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Fri, 3 May 2013 15:21:23 +0200 Subject: [PATCH 1/1] Drop some redundant defined(_WIN64) When it is already defined(_WIN32). According to Microsoft documentation: http://msdn.microsoft.com/en-us/library/b0084kay.aspx _WIN32 Defined for applications for Win32 and Win64. Always defined. _WIN64 Defined for applications for Win64. Patch suggested by Joona. No functional change. --- src/misc.cpp | 4 ++-- src/platform.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/misc.cpp b/src/misc.cpp index 477fb392..cad8e39d 100644 --- a/src/misc.cpp +++ b/src/misc.cpp @@ -178,7 +178,7 @@ void start_logger(bool b) { Logger::start(b); } int cpu_count() { -#if defined(_WIN32) || defined(_WIN64) +#if defined(_WIN32) SYSTEM_INFO s; GetSystemInfo(&s); return s.dwNumberOfProcessors; @@ -204,7 +204,7 @@ int cpu_count() { void timed_wait(WaitCondition& sleepCond, Lock& sleepLock, int msec) { -#if defined(_WIN32) || defined(_WIN64) +#if defined(_WIN32) int tm = msec; #else timespec ts, *tm = &ts; diff --git a/src/platform.h b/src/platform.h index ad02575b..334a0eec 100644 --- a/src/platform.h +++ b/src/platform.h @@ -43,7 +43,7 @@ typedef unsigned __int64 uint64_t; # include // Used by sysconf(_SC_NPROCESSORS_ONLN) #endif -#if !defined(_WIN32) && !defined(_WIN64) // Linux - Unix +#if !defined(_WIN32) // Linux - Unix # include typedef timeval sys_time_t; -- 2.39.2