k-tana-zero/libs/libc/memcpy.c

13 lines
179 B
C
Raw Normal View History

#include <string.h>
void *memcpy(void *dest, const void *src, size_t n)
{
const char *s = src;
char *d = dest;
for (size_t i = 0; i < n; i++)
*d++ = *s++;
return dest;
}