Go to the documentation of this file. 1 #ifndef SIGNALHANDLING_H_
2 #define SIGNALHANDLING_H_
5 #include <QSocketNotifier>
31 static void Init(QObject *parent =
nullptr);
32 static void Done(
void);
36 static bool IsExiting(
void) {
return s_exit_program; }
40 static void signalHandler(
int signum,
siginfo_t *info,
void *context);
44 void handleSignal(
void);
53 QSocketNotifier *m_notifier {
nullptr};
54 char *m_sigStack {
nullptr};
static std::array< int, 2 > s_sigFd
void(*)(void) SigHandlerFunc
A container object to handle UNIX signals in the Qt space correctly.
static QMutex s_singletonLock
static volatile bool s_exit_program
static SignalHandler * s_singleton
QMap< int, SigHandlerFunc > m_sigMap
static bool IsExiting(void)