typedef unsigned char byte;
void *memcpy(void *pvTo, const void *pvFrom, size_t size) { assert((pvTo != NULL) && (pvFrom != NULL)); byte *pbTo = (byte *) pvTo; byte *pbFrom = (byte *) pvFrom; while(size -- > 0 ) *pbTo++ = *pbFrom++ ; return pvTo; }
char *strcpy(char *des, const char *src) { assert((des != NULL) && (src != NULL)); char *add = des; while ((*des++ = *src++ ) != '\0'); return add; }