about summary refs log tree commit diff homepage
path: root/runtime/klee-libc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/klee-libc')
-rw-r--r--runtime/klee-libc/fortify-klibc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/runtime/klee-libc/fortify-klibc.c b/runtime/klee-libc/fortify-klibc.c
index ed4a3033..12f80345 100644
--- a/runtime/klee-libc/fortify-klibc.c
+++ b/runtime/klee-libc/fortify-klibc.c
@@ -13,6 +13,11 @@
 
 #include <string.h>
 
+#ifdef __APPLE__
+/* macOS does not provide mempcpy in string.h */
+void *mempcpy(void *destaddr, void const *srcaddr, size_t len);
+#endif
+
 void *__mempcpy_chk(void *dest, const void *src, size_t len, size_t destlen) {
   if (len > destlen)
     klee_report_error(__FILE__, __LINE__, "mempcpy overflow", "ptr.err");