summaryrefslogtreecommitdiffstats
path: root/libc/bionic/__memcpy_chk.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libc/bionic/__memcpy_chk.cpp')
-rw-r--r--libc/bionic/__memcpy_chk.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/bionic/__memcpy_chk.cpp b/libc/bionic/__memcpy_chk.cpp
index b36cfdd..a3d744c 100644
--- a/libc/bionic/__memcpy_chk.cpp
+++ b/libc/bionic/__memcpy_chk.cpp
@@ -45,7 +45,7 @@
extern "C" void *__memcpy_chk(void *dest, const void *src,
size_t copy_amount, size_t dest_len)
{
- if (__builtin_expect(copy_amount > dest_len, 0)) {
+ if (__predict_false(copy_amount > dest_len)) {
__fortify_chk_fail("memcpy buffer overflow",
BIONIC_EVENT_MEMCPY_BUFFER_OVERFLOW);
}