From 3b2e6bc9acf5223db6e9967e46066219c76ee56f Mon Sep 17 00:00:00 2001 From: Nick Kralevich Date: Tue, 30 Apr 2013 14:19:23 -0700 Subject: [PATCH] libc: upgrade strrchr to FORTIFY_SOURCE=2 Change-Id: I4c34c2ce22c5092c4446dc1ab55f37604c1c223f --- libc/include/string.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc/include/string.h b/libc/include/string.h index c0df686e3..b4cf70e7e 100644 --- a/libc/include/string.h +++ b/libc/include/string.h @@ -249,7 +249,7 @@ extern char* __strrchr_chk(const char *, int, size_t); __BIONIC_FORTIFY_INLINE char* strrchr(const char *s, int c) { - size_t bos = __builtin_object_size(s, 0); + size_t bos = __bos(s); // Compiler doesn't know destination size. Don't call __strrchr_chk if (bos == __BIONIC_FORTIFY_UNKNOWN_SIZE) {