Namespaces | Typedefs | Functions
UnixSignalHandlers.cc File Reference
#include "art/Utilities/UnixSignalHandlers.h"
#include "canvas/Utilities/DebugMacros.h"
#include <atomic>
#include <csignal>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <exception>
#include <iostream>

Go to the source code of this file.

Namespaces

 art
 

Typedefs

using my_sigaction_func_t = void(*)(int, siginfo_t *, void *)
 

Functions

static void handle_sigusr2 (int which, siginfo_t *, void *)
 
void art::setupSignals (bool want_sigint_enabled)
 

Typedef Documentation

using my_sigaction_func_t = void (*)(int, siginfo_t*, void*)

Definition at line 17 of file UnixSignalHandlers.cc.

Function Documentation

static void handle_sigusr2 ( int  which,
siginfo_t *  ,
void *   
)
static

Definition at line 24 of file UnixSignalHandlers.cc.

25 {
26  FDEBUG(1) << "in sigusr2 handler\n";
27  if ((which == SIGINT) && (art::shutdown_flag > 0)) {
28  cerr << "User signal SIGINT terminating the process\n";
29  terminate();
30  }
31  art::shutdown_flag = which;
32 }
std::atomic< int > shutdown_flag
#define FDEBUG(LEVEL)
Definition: DebugMacros.h:25