From 29ae3ed4d5b83eec43598d6cd7949bccb41c8083 Mon Sep 17 00:00:00 2001 From: Brian Callahan Date: Thu, 23 Feb 2023 17:19:37 -0500 Subject: [PATCH] OpenBSD has removed the syscall() function from its libc, so we need to use getthrid() directly in lib/bcheck.c --- lib/bcheck.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/bcheck.c b/lib/bcheck.c index d5d9c4c5..b8dd1c53 100644 --- a/lib/bcheck.c +++ b/lib/bcheck.c @@ -225,7 +225,7 @@ typedef struct alloca_list_struct { #define BOUND_GET_TID(id) id = GetCurrentThreadId() #elif defined(__OpenBSD__) #define BOUND_TID_TYPE pid_t -#define BOUND_GET_TID(id) id = syscall (SYS_getthrid) +#define BOUND_GET_TID(id) id = getthrid() #elif defined(__FreeBSD__) #define BOUND_TID_TYPE pid_t #define BOUND_GET_TID(id) syscall (SYS_thr_self, &id)