Go to the source code of this file.
Function Documentation
| int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 76 of file repro.cxx.
{
#ifndef _WIN32
if ( signal( SIGPIPE, SIG_IGN) == SIG_ERR)
{
cerr << "Couldn't install signal handler for SIGPIPE" << endl;
exit(-1);
}
#endif
if ( signal( SIGINT, signalHandler ) == SIG_ERR )
{
cerr << "Couldn't install signal handler for SIGINT" << endl;
exit( -1 );
}
if ( signal( SIGTERM, signalHandler ) == SIG_ERR )
{
cerr << "Couldn't install signal handler for SIGTERM" << endl;
exit( -1 );
}
initNetwork();
#if defined(WIN32) && defined(_DEBUG) && defined(LEAK_CHECK)
{ FindMemoryLeaks fml;
#endif
ReproRunner repro;
if(!repro.run(argc, argv))
{
cerr << "Failed to start repro, exiting..." << endl;
exit(-1);
}
while (!finished)
{
#ifdef WIN32
Sleep(1000);
#else
usleep(100000);
#endif
}
repro.shutdown();
#if defined(WIN32) && defined(_DEBUG) && defined(LEAK_CHECK)
}
#endif
return 0;
}
| static void signalHandler |
( |
int |
signo | ) |
[static] |
Definition at line 19 of file repro.cxx.
{
std::cerr << "Shutting down" << endl;
finished = true;
}
Variable Documentation