summaryrefslogtreecommitdiffstats
path: root/src/Globals.h
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-12-07 18:15:23 +0100
committerMattes D <github@xoft.cz>2014-12-07 18:15:23 +0100
commit8ad1afcc1b98c03bd77b0d85236643ba04795d38 (patch)
treee340889a2d505f10fd45a80f7b951f3165d6294a /src/Globals.h
parentcEvent: Changed chrono duration resolution. (diff)
parentFixed format warning. (diff)
downloadcuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar.gz
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar.bz2
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar.lz
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar.xz
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.tar.zst
cuberite-8ad1afcc1b98c03bd77b0d85236643ba04795d38.zip
Diffstat (limited to 'src/Globals.h')
-rw-r--r--src/Globals.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Globals.h b/src/Globals.h
index eb59f499e..61f500db9 100644
--- a/src/Globals.h
+++ b/src/Globals.h
@@ -184,9 +184,9 @@ template class SizeChecker<UInt16, 2>;
// OS-dependent stuff:
#ifdef _WIN32
- #define WIN32_LEAN_AND_MEAN
- #define _WIN32_WINNT 0x501 // We want to target WinXP and higher
+ #define WIN32_LEAN_AND_MEAN
+ #define _WIN32_WINNT _WIN32_WINNT_WS03 // We want to target Windows XP with Service Pack 2 & Windows Server 2003 with Service Pack 1 and higher
#include <Windows.h>
#include <winsock2.h>
@@ -241,6 +241,7 @@ template class SizeChecker<UInt16, 2>;
// STL stuff:
+#include <chrono>
#include <vector>
#include <list>
#include <deque>
@@ -259,13 +260,12 @@ template class SizeChecker<UInt16, 2>;
#ifndef TEST_GLOBALS
// Common headers (part 1, without macros):
#include "StringUtils.h"
- #include "OSSupport/Sleep.h"
#include "OSSupport/CriticalSection.h"
#include "OSSupport/Semaphore.h"
#include "OSSupport/Event.h"
- #include "OSSupport/Thread.h"
#include "OSSupport/File.h"
#include "Logger.h"
+ #include "OSSupport/StackTrace.h"
#else
// Logging functions
void inline LOGERROR(const char* a_Format, ...) FORMATSTRING(1, 2);
@@ -351,14 +351,14 @@ void inline LOGD(const char* a_Format, ...)
#else
#ifdef _DEBUG
- #define ASSERT( x) ( !!(x) || ( LOGERROR("Assertion failed: %s, file %s, line %i", #x, __FILE__, __LINE__), assert(0), 0))
+ #define ASSERT( x) ( !!(x) || ( LOGERROR("Assertion failed: %s, file %s, line %i", #x, __FILE__, __LINE__), PrintStackTrace(), assert(0), 0))
#else
#define ASSERT(x) ((void)(x))
#endif
#endif
// Pretty much the same as ASSERT() but stays in Release builds
-#define VERIFY( x) ( !!(x) || ( LOGERROR("Verification failed: %s, file %s, line %i", #x, __FILE__, __LINE__), exit(1), 0))
+#define VERIFY( x) ( !!(x) || ( LOGERROR("Verification failed: %s, file %s, line %i", #x, __FILE__, __LINE__), PrintStackTrace(), exit(1), 0))
// Same as assert but in all Self test builds
#ifdef SELF_TEST