RTP Audio System  2.0.0
breakdetector.cc File Reference
#include "tdsystem.h"
#include "breakdetector.h"
#include "tools.h"
#include <signal.h>

Defines

#define KILL_AFTER_TIMEOUT
#define KILL_TIMEOUT   2000000

Functions

void breakDetector (int signum)
void installBreakDetector ()
void uninstallBreakDetector ()
bool breakDetected ()
void sendBreak (const bool quiet)

Variables

static bool DetectedBreak = false
static bool PrintedBreak = false
static bool Quiet = false
static pid_t MainThreadPID = getpid()
static bool PrintedKill = false
static card64 LastDetection = (card64)-1

Define Documentation

#define KILL_TIMEOUT   2000000

Function Documentation

bool breakDetected ( )

Check, if break has been detected.

void breakDetector ( int  signum)

Install break handler.

void sendBreak ( const bool  quiet = false)

Send break to main thread.

Parameters:
quiettrue to print no break message in breakDetected(), false otherwise (default).

Uninstall break handler.


Variable Documentation

bool DetectedBreak = false [static]
card64 LastDetection = (card64)-1 [static]
pid_t MainThreadPID = getpid() [static]
bool PrintedBreak = false [static]
bool PrintedKill = false [static]
bool Quiet = false [static]
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines