Home | History | Annotate | Download | only in seccomp-bpf

Lines Matching defs:trap

19 #include "sandbox/linux/seccomp-bpf/trap.h"
68 Trap::Trap()
90 Trap *Trap::GetInstance() {
94 // Also, this is not a normal singleton. Once created, the global trap
97 global_trap_ = new Trap();
99 SANDBOX_DIE("Failed to allocate global trap handler");
105 void Trap::SigSysAction(int nr, siginfo_t *info, void *void_context) {
108 "for Trap() handling.");
113 void Trap::SigSys(int nr, siginfo_t *info, void *void_context) {
198 bool Trap::TrapKey::operator<(const TrapKey& o) const {
208 ErrorCode Trap::MakeTrap(TrapFnc fnc, const void *aux, bool safe) {
212 ErrorCode Trap::MakeTrapImpl(TrapFnc fnc, const void *aux, bool safe) {
237 // us to associate trap with the appropriate handler. The kernel allows us
239 // avoid 0, as it could be confused for a trap without any specific id.
306 bool Trap::SandboxDebuggingAllowedByUser() const {
312 bool Trap::EnableUnsafeTrapsInSigSysHandler() {
313 Trap *trap = GetInstance();
314 if (!trap->has_unsafe_traps_) {
320 if (trap->SandboxDebuggingAllowedByUser()) {
324 trap->has_unsafe_traps_ = true;
331 return trap->has_unsafe_traps_;
334 ErrorCode Trap::ErrorCodeFromTrapId(uint16_t id) {
342 Trap *Trap::global_trap_;