#include <uhal/SigBusGuard.hpp>
Public Member Functions | |
SigBusGuard () | |
~SigBusGuard () | |
void | protect (const std::function< void()> &, const std::string &) |
Static Public Member Functions | |
static void | blockSIGBUS () |
Static Private Member Functions | |
static void | handle (int) |
Private Attributes | |
std::lock_guard< std::mutex > | mLockGuard |
struct sigaction | mAction |
struct sigaction | mOriginalAction |
sigset_t | mOriginalMask |
Static Private Attributes | |
static std::mutex | sMutex |
static sigjmp_buf | sEnv |
static volatile sig_atomic_t | sProtected = 0 |
Definition at line 58 of file SigBusGuard.hpp.
uhal::SigBusGuard::SigBusGuard | ( | ) |
Definition at line 47 of file SigBusGuard.cpp.
uhal::SigBusGuard::~SigBusGuard | ( | ) |
Definition at line 83 of file SigBusGuard.cpp.
References uhal::Debug, uhal::Error, uhal::Integer(), uhal::log(), mOriginalAction, mOriginalMask, and uhal::Quote().
|
static |
Definition at line 121 of file SigBusGuard.cpp.
References uhal::Integer(), uhal::log(), and uhal::Quote().
Referenced by PYBIND11_MODULE().
|
staticprivate |
Definition at line 135 of file SigBusGuard.cpp.
References uhal::message, sEnv, and sProtected.
void uhal::SigBusGuard::protect | ( | const std::function< void()> & | aAccess, |
const std::string & | aMessage | ||
) |
Definition at line 98 of file SigBusGuard.cpp.
References uhal::log(), sEnv, and sProtected.
Referenced by uhal::Mmap::File::read(), and uhal::Mmap::File::write().
|
private |
Definition at line 71 of file SigBusGuard.hpp.
|
private |
Definition at line 70 of file SigBusGuard.hpp.
|
private |
Definition at line 72 of file SigBusGuard.hpp.
Referenced by ~SigBusGuard().
|
private |
Definition at line 73 of file SigBusGuard.hpp.
Referenced by ~SigBusGuard().
|
staticprivate |
Definition at line 76 of file SigBusGuard.hpp.
|
staticprivate |
Definition at line 75 of file SigBusGuard.hpp.
|
staticprivate |
Definition at line 77 of file SigBusGuard.hpp.