// Copyright 2008-2009 Segher Boessenkool // This code is licensed to you under the terms of the GNU GPL, version 2; // see file COPYING or http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt #include void *memset(void *b, int c, size_t len) { size_t i; for (i = 0; i < len; i++) ((unsigned char *)b)[i] = c; return b; } void *memcpy(void *dst, const void *src, size_t len) { size_t i; for (i = 0; i < len; i++) ((unsigned char *)dst)[i] = ((unsigned char *)src)[i]; return dst; }