Clang: implement memset local to C++ runtime

Using Genode::memset with Clang results in recursion.
This commit is contained in:
Ehmry - 2019-09-28 12:21:07 +02:00
parent f42e7f1ff4
commit 44f2c86a91
1 changed files with 2 additions and 1 deletions

View File

@ -166,7 +166,8 @@ void *memmove(void *dst, const void *src, size_t n)
extern "C" __attribute__((weak))
void *memset(void *s, int c, size_t n)
{
return Genode::memset(s, c, n);
while (n--) ((char *)s)[n] = c;
return s;
}