Retro68/gcc/libgcc/memset.c

12 lines
177 B
C
Raw Normal View History

2012-03-27 23:13:14 +00:00
/* Public domain. */
#include <stddef.h>
void *
memset (void *dest, int val, size_t len)
{
unsigned char *ptr = dest;
while (len-- > 0)
*ptr++ = val;
return dest;
}