mirror of
https://github.com/polserver/polserver
synced 2026-08-13 08:23:08 -04:00
Include cleanup Reworked buildsystem (Linux only) Removed dynamic libs, Linux now again uses static linking (like windows)
33 lines
636 B
C++
33 lines
636 B
C++
/** @file
|
|
*
|
|
* @par History
|
|
*/
|
|
|
|
|
|
#include "checkpnt.h"
|
|
|
|
#include "../clib/logfacility.h"
|
|
#include "../plib/systemstate.h"
|
|
#include "globals/state.h"
|
|
|
|
namespace Pol
|
|
{
|
|
namespace Core
|
|
{
|
|
void checkpoint( const char* msg, unsigned short minlvl /* = 11 */ )
|
|
{
|
|
Core::stateManager.last_checkpoint = msg;
|
|
if ( Plib::systemstate.config.loglevel >= minlvl )
|
|
{
|
|
POLLOG_INFO << "checkpoint: " << msg << "\n";
|
|
}
|
|
}
|
|
|
|
Checkpoint::Checkpoint( const char* file ) : _file( file ), _line( 0 ) {}
|
|
Checkpoint::~Checkpoint()
|
|
{
|
|
if ( _line )
|
|
POLLOG_ERROR << "Abnormal end after checkpoint: File " << _file << ", line " << _line << "\n";
|
|
}
|
|
}
|
|
}
|