summaryrefslogtreecommitdiffstats
path: root/lib/libc/string/memcpy.c
diff options
context:
space:
mode:
authorguenther <guenther@openbsd.org>2017-11-29 05:13:57 +0000
committerguenther <guenther@openbsd.org>2017-11-29 05:13:57 +0000
commitea6088e7d368d53c49ebfdf4520275cec2f78f5b (patch)
treea7a8d82d7543c1ee5938393be3730e485b342723 /lib/libc/string/memcpy.c
parentturns out you dont have to configure a vsi as the default in a veb. (diff)
downloadwireguard-openbsd-ea6088e7d368d53c49ebfdf4520275cec2f78f5b.tar.xz
wireguard-openbsd-ea6088e7d368d53c49ebfdf4520275cec2f78f5b.zip
clang doesn't propagate attributes like "asm labels" and "visibility(hidden)"
to builtins like mem{set,cpy,move} and __stack_smash_handler. So, when building with clang, instead mark those as protected visibility to get rid of the PLT relocations. We can't take the address of them then, but that's ok: it's a build-time error not a run-time error. ok kettenis@
Diffstat (limited to 'lib/libc/string/memcpy.c')
-rw-r--r--lib/libc/string/memcpy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/string/memcpy.c b/lib/libc/string/memcpy.c
index a2516ed041a..19fddc0ab5f 100644
--- a/lib/libc/string/memcpy.c
+++ b/lib/libc/string/memcpy.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: memcpy.c,v 1.3 2017/08/14 17:10:02 guenther Exp $ */
+/* $OpenBSD: memcpy.c,v 1.4 2017/11/29 05:13:57 guenther Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
@@ -106,4 +106,4 @@ memcpy(void *dst0, const void *src0, size_t length)
done:
return (dst0);
}
-DEF_STRONG(memcpy);
+DEF_BUILTIN(memcpy);