mescc: Tinycc support: memmove.
* mlibc/libc-mes+tcc.c (memmove): Implement.
This commit is contained in:
parent
af8335dc7a
commit
ec3c031b2f
|
@ -194,8 +194,13 @@ memcpy (void *dest, void const *src, size_t n)
|
|||
void *
|
||||
memmove (void *dest, void const *src, size_t n)
|
||||
{
|
||||
eputs ("memmove stub\n");
|
||||
return 0;
|
||||
if (dest < src)
|
||||
return memcpy (dest, src, n);
|
||||
char *p = dest + n;
|
||||
char const *q = src +n;
|
||||
while (n--)
|
||||
*--p = *--q;
|
||||
return dest;
|
||||
}
|
||||
|
||||
void *
|
||||
|
|
Loading…
Reference in a new issue