From e32a9f293100c0e9330974c97b5d508fed754f81 Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Tue, 16 Apr 2024 21:34:19 +0200 Subject: [PATCH] Update common_arm64.h --- common_arm64.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common_arm64.h b/common_arm64.h index 2ab34686e..d80b9e434 100644 --- a/common_arm64.h +++ b/common_arm64.h @@ -63,7 +63,8 @@ static __inline int WhereAmI(void){ :"=r" (ret) :: "memory" ); - if (ret > MAX_CPU_NUMBER) ret = MAX_CPU_NUMBER; + ret +=1; + if ((int)ret <0) ret = 0; return (int)ret; }