EMILE/libunix/strncpy.c

16 lines
264 B
C
Raw Normal View History

2005-11-12 21:30:19 +00:00
/*
*
* (c) 2004,2005 Laurent Vivier <Laurent@lvivier.info>
2005-11-12 21:30:19 +00:00
*
*/
2005-11-08 02:04:54 +00:00
#include <sys/types.h>
char *strncpy (char *__restrict __dest,
__const char *__restrict __src, size_t __n)
{
while ( (*__dest ++ = *__src++) && __n--);
return __dest;
}