kern

diff src/klibc/string.c @ 0:662ff2170531

starting the kernel
author John Tsiombikas <nuclear@member.fsf.org>
date Wed, 01 Dec 2010 22:02:42 +0200
parents
children ebe5e0e44a9d
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/klibc/string.c	Wed Dec 01 22:02:42 2010 +0200
     1.3 @@ -0,0 +1,11 @@
     1.4 +#include <string.h>
     1.5 +
     1.6 +void memset(void *s, int c, size_t sz)
     1.7 +{
     1.8 +	int i;
     1.9 +	char *ptr = s;
    1.10 +
    1.11 +	for(i=0; i<sz; i++) {
    1.12 +		*ptr++ = c;
    1.13 +	}
    1.14 +}