From 011fd50bcd15501873a6f3605eea7e0e0a153d7a Mon Sep 17 00:00:00 2001 From: yangao1 Date: Wed, 21 May 2025 11:01:25 +0800 Subject: [PATCH] libc/arch_libc.c:fix bug for macro LIBC_ARCH_STRCHRNUL config ARM64_STRCHRNUL bool "Enable optimized strchrnul() for ARM64" default n select LIBC_ARCH_STRCHRNUL depends on ARCH_TOOLCHAIN_GNU ---help--- Enable optimized ARM64 specific strchrnul() library function Signed-off-by: yangao1 --- libs/libc/machine/arch_libc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libs/libc/machine/arch_libc.c b/libs/libc/machine/arch_libc.c index af4017b2077..0cce4c4d227 100644 --- a/libs/libc/machine/arch_libc.c +++ b/libs/libc/machine/arch_libc.c @@ -73,7 +73,7 @@ FAR char *ARCH_LIBCFUN(strncpy)(FAR char *dest, FAR char *ARCH_LIBCFUN(strchr)(FAR const char *s, int c); #endif -#ifdef CONFIG_LIBC_ARCH_STRCHNUL +#ifdef CONFIG_LIBC_ARCH_STRCHRNUL FAR char *ARCH_LIBCFUN(strchrnul)(FAR const char *s, int c); #endif @@ -240,8 +240,8 @@ FAR char *strchr(FAR const char *s, int c) } #endif -#ifdef CONFIG_LIBC_ARCH_STRCHNUL -FAR char *strchrnul(FAR const char *s, int c); +#ifdef CONFIG_LIBC_ARCH_STRCHRNUL +FAR char *strchrnul(FAR const char *s, int c) { # ifdef CONFIG_MM_KASAN_INSTRUMENT # ifndef CONFIG_MM_KASAN_DISABLE_READS_CHECK