summaryrefslogtreecommitdiffstats
path: root/sw/z80/libc/string.c
blob: fd6a7ffc21e775d31cffb51147fc57994332fd91 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include "string.h"

void *memcpy(void *dest, void *src, size_t n)
{
    char *dp = dest;
    char *sp = src;

    while (n--) {
        *dp++ = *sp++;
    }

    return dest;
}