From: George Burgess IV Date: Tue, 4 Apr 2017 01:03:36 +0000 (-0700) Subject: libc: use __bos instead of __bos0 for strchr. X-Git-Tag: android-x86-8.1-r1~51^2^2~54^2^2^2 X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=bce9a7d51898f73d8e3cef2c4a437bf08698430f;p=android-x86%2Fbionic.git libc: use __bos instead of __bos0 for strchr. I dunno why I used __bos0 in the first place; clang's strrchr (and GCC's strchr+strrchr) both use __bos. Bug: 34747525 Test: m. Device still boots. cts -m BionicUnitTests shows no new failures. Change-Id: Ifec0e05a6a1144fa3e3ac70562af3ec57c09c194 --- diff --git a/libc/include/string.h b/libc/include/string.h index 26bd93f71..0cbd61c3f 100644 --- a/libc/include/string.h +++ b/libc/include/string.h @@ -358,9 +358,9 @@ size_t strlen(const char* const _Nonnull s __pass_object_size0) #if __ANDROID_API__ >= __ANDROID_API_J_MR2__ __BIONIC_FORTIFY_INLINE -char* strchr(const char* const _Nonnull s __pass_object_size0, int c) +char* strchr(const char* const _Nonnull s __pass_object_size, int c) __overloadable { - size_t bos = __bos0(s); + size_t bos = __bos(s); if (bos == __BIONIC_FORTIFY_UNKNOWN_SIZE) { return __builtin_strchr(s, c);