std: use wrappers from raise() rather than raw syscalls

This commit is contained in:
daurnimator 2019-12-22 12:23:28 +11:00
parent 6de4bd850c
commit 59348240d7
No known key found for this signature in database
GPG Key ID: 45B429A8F9D9D22A

View File

@ -228,8 +228,8 @@ pub fn raise(sig: u8) RaiseError!void {
// block application signals
_ = linux.sigprocmask(SIG_BLOCK, &linux.app_mask, &set);
const tid = linux.syscall0(linux.SYS_gettid);
const rc = linux.syscall2(linux.SYS_tkill, tid, sig);
const tid = linux.gettid();
const rc = linux.tkill(tid, sig);
// restore signal mask
_ = linux.sigprocmask(SIG_SETMASK, &set, null);