1
0
Fork 0
mirror of https://github.com/tailix/kernel.git synced 2024-10-30 12:03:52 -04:00
kernel/libk/strncpy.c
2017-11-04 11:43:55 +00:00

10 lines
210 B
C

char *kstrncpy(char *const dest, const char *const src, const unsigned long length)
{
for (unsigned long i = 0; i < length; ++i) {
dest[i] = src[i];
}
dest[length] = 0;
return dest;
}