COSC_4P82_Assignment_1/lib/beagle-3.0.3/tests/TransportTCPIPOp/DefaultSignalHandler.cpp

24 lines
437 B
C++

#include "DefaultSignalHandler.hpp"
DefaultSignalHandler::DefaultSignalHandler()
{
setCustomAction(eSigInt);
setCustomAction(eSigTerm);
}
DefaultSignalHandler::~DefaultSignalHandler()
{}
void
DefaultSignalHandler::main(SignalType inSignalNumber)
{
switch(inSignalNumber) {
case eSigInt:
case eSigTerm:
throw "This is the default signal handler cleaning things up.";
break;
default:
break;
}
}