From 891f1010bbdc1351bda8d2a6139094a14bdfd5e1 Mon Sep 17 00:00:00 2001 From: Danny Holman Date: Sat, 24 Feb 2024 14:47:25 -0600 Subject: kernel: string: add a strcpy function Add an implmentation of strcpy. This function is used in several places in the kernel to copy strings between memory addresses. Signed-off-by: Danny Holman --- include/kernel/string.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/kernel/string.h b/include/kernel/string.h index f9a8eed..76bf610 100644 --- a/include/kernel/string.h +++ b/include/kernel/string.h @@ -10,6 +10,7 @@ void* memset(void *str, int c, size_t n); int strncmp(const char *str1, const char *str2, size_t n); int strcmp(const char *str1, const char *str2); size_t strlen(const char *str); +char* strncpy(char* __restrict dest, const char* __restrict src, size_t n); char* strcpy(char* __restrict dest, const char* __restrict src); char* strcat(char* __restrict dest, const char* __restrict src); char* strtok(char* __restrict str, const char* __restrict delim); -- cgit v1.2.3