From 4c45793ec141378f916faef0052356034bc7d678 Mon Sep 17 00:00:00 2001 From: Haneef Mubarak Date: Tue, 26 May 2020 16:16:19 -0700 Subject: [PATCH] fix __movsb typecast error MSVC --- include/mimalloc-internal.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/include/mimalloc-internal.h b/include/mimalloc-internal.h index 43f72a11..6cdf0c03 100644 --- a/include/mimalloc-internal.h +++ b/include/mimalloc-internal.h @@ -183,7 +183,10 @@ bool _mi_page_is_valid(mi_page_t* page); #include #define _mi_memcpy _mi_memcpy_rep_movsb static inline void _mi_memcpy_rep_movsb (void *d, const void *s, size_t n) { - __movsb(d, s, n); + unsigned char* Destination = (unsigned char*) d; + unsigned const char* Source = (unsigned const char*) s; + size_t Count = n; + __movsb(Destination, Source, Count); return; } #else