iw4x-client/src/Components/Modules/News.hpp
momo5502 80e88f1572 [General] Fix a few memory leaks in threads
Destroying threads past when uninitializing the library is illegal
2017-01-24 06:32:04 +01:00

28 lines
464 B
C++

#pragma once
namespace Components
{
class News : public Component
{
public:
News();
~News();
#if defined(DEBUG) || defined(FORCE_UNIT_TESTS)
const char* getName() override { return "News"; };
#endif
void preDestroy() override;
bool unitTest() override;
private:
static std::thread Thread;
static bool Terminate;
static void CheckForUpdate();
static void ExitProcessStub(unsigned int exitCode);
static const char* GetNewsText();
};
}