* make_checkpoint.h: added --monitor_with_CtrlC option in order to monitor only when Ctrl-C is pressed

This commit is contained in:
Caner Candan 2012-06-22 17:41:46 +02:00
commit 46b3f77d9c
3 changed files with 52 additions and 3 deletions

View file

@ -36,6 +36,7 @@
#include <utils/eoGnuplot1DSnapshot.h>
#endif
#include <utils/eoCheckPoint.h>
#include <utils/eoSignal.h>
#include <utils/eoStat.h>
#include <utils/eoScalarFitnessStat.h>
#include <utils/eoAssembledFitnessStat.h>

View file

@ -52,13 +52,23 @@ public :
eoSignal( int sig = SIGINT ) : eoCheckPoint<EOT>( _dummyContinue ), _sig( sig )
{
::signals_called[_sig] = false;
#ifndef _WINDOWS
#ifdef SIGQUIT
::signal( _sig, handler );
#endif // !SIGQUIT
#endif // !_WINDOWS
}
eoSignal( eoContinue<EOT>& _cont, int sig = SIGINT ) : eoCheckPoint<EOT>( _cont ), _sig( sig )
{
::signals_called[_sig] = false;
#ifndef _WINDOWS
#ifdef SIGQUIT
::signal( _sig, handler );
#endif // !SIGQUIT
#endif // !_WINDOWS
}
bool operator()( const eoPop<EOT>& _pop )