Fixed per-class thread safety

This commit is contained in:
Lynix
2012-05-08 08:20:57 +02:00
parent 45f3fc4e28
commit e91cde657b
44 changed files with 90 additions and 145 deletions

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_CLOCK_CPP
#include <Nazara/Core/Clock.hpp>
#include <Nazara/Core/Error.hpp>
@@ -15,6 +13,7 @@
#error OS not handled
#endif
#define NAZARA_CLASS_CLOCK
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_DIRECTORY_CPP
#include <Nazara/Core/Directory.hpp>
#include <Nazara/Core/Error.hpp>
#include <Nazara/Core/File.hpp>
@@ -17,6 +15,7 @@
#error OS not handled
#endif
#define NAZARA_CLASS_DIRECTORY
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_DYNLIB_CPP
#include <Nazara/Core/DynLib.hpp>
#include <Nazara/Core/Config.hpp>
#include <Nazara/Core/Error.hpp>
@@ -19,6 +17,8 @@
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>
#define NAZARA_DYNLIB_CPP
NzDynLib::NzDynLib(const NzString& libraryPath) :
m_path(libraryPath),
m_impl(nullptr)

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_ERROR_CPP
#include <Nazara/Core/Error.hpp>
#include <Nazara/Core/Log.hpp>
#include <cstdlib>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_FILE_CPP
#include <Nazara/Core/File.hpp>
#include <Nazara/Core/Config.hpp>
#include <Nazara/Core/Error.hpp>
@@ -21,6 +19,7 @@
#error OS not handled
#endif
#define NAZARA_CLASS_FILE
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,14 +2,11 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_HASHDIGEST_CPP
#include <Nazara/Core/HashDigest.hpp>
#include <Nazara/Core/Error.hpp>
#include <cstdio>
#include <cstring>
#include <utility>
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>
NzHashDigest::NzHashDigest() :

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_LOCK_CPP
#include <Nazara/Core/Lock.hpp>
#include <Nazara/Core/Mutex.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_LOG_CPP
#include <Nazara/Core/Log.hpp>
#include <Nazara/Core/File.hpp>
#include <Nazara/Core/StringStream.hpp>
@@ -14,6 +12,7 @@
#include <cstdio>
#endif
#define NAZARA_CLASS_LOG
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_MUTEX_CPP
#include <Nazara/Core/Mutex.hpp>
#if defined(NAZARA_PLATFORM_WINDOWS)

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_SEMAPHORE_CPP
#include <Nazara/Core/Semaphore.hpp>
#if defined(NAZARA_PLATFORM_WINDOWS)

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_STRING_CPP
#include <Nazara/Core/String.hpp>
#include <Nazara/Core/Config.hpp>
#include <Nazara/Core/Error.hpp>
@@ -15,6 +13,8 @@
#include <cstring>
#include <sstream>
#include <Utfcpp/utf8.h>
#define NAZARA_CLASS_STRING
#include <Nazara/Core/ThreadSafety.hpp>
#include <Nazara/Core/Debug.hpp>

View File

@@ -2,11 +2,11 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_STRINGSTREAM_CPP
#include <Nazara/Core/StringStream.hpp>
#include <Nazara/Core/Debug.hpp>
#define NAZARA_STRINGSTREAM_CPP
NzStringStream::NzStringStream() :
m_bufferSize(0)
{

View File

@@ -4,8 +4,6 @@
// Inspiré du code de la SFML par Laurent Gomila
#define NAZARA_THREAD_CPP
#include <Nazara/Core/Thread.hpp>
#include <Nazara/Core/Error.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_THREADCONDITION_CPP
#include <Nazara/Core/ThreadCondition.hpp>
#include <Nazara/Core/Mutex.hpp>

View File

@@ -2,8 +2,6 @@
// This file is part of the "Nazara Engine".
// For conditions of distribution and use, see copyright notice in Config.hpp
#define NAZARA_UNICODE_CPP
#include <Nazara/Core/Unicode.hpp>
#include <Nazara/Core/Debug.hpp>