memmove() entry point is declared with NENTRY() and isn't consecutive
authorguenther <guenther@openbsd.org>
Thu, 18 May 2023 16:14:05 +0000 (16:14 +0000)
committerguenther <guenther@openbsd.org>
Thu, 18 May 2023 16:14:05 +0000 (16:14 +0000)
with an ENTRY(), so it needs its own endbr64 for IBT

ok deraadt@

lib/libc/arch/amd64/string/memmove.S

index 67f2e41..2d73e60 100644 (file)
@@ -45,6 +45,7 @@ ENTRY_NB(bcopy)
        /* fall into memmove */
 
 NENTRY(memmove)
+       endbr64
        RETGUARD_SETUP(memmove, r10)
        movq    %rdi,%r11       /* save dest */
        movq    %rdx,%rcx