X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/bb7ce16533fb6c1384775dea6e1150e74c229daf..b60166b327a9108b07e3069fa6568a451529ffd9:/lunaix-os/libs/klibc/string/strcpy.c diff --git a/lunaix-os/libs/klibc/string/strcpy.c b/lunaix-os/libs/klibc/string/strcpy.c index 1f7a06d..86032d9 100644 --- a/lunaix-os/libs/klibc/string/strcpy.c +++ b/lunaix-os/libs/klibc/string/strcpy.c @@ -9,12 +9,12 @@ strcpy(char* dest, const char* src) dest[i] = c; i++; } - dest[i] = '\0'; - return dest; + dest[i++] = '\0'; + return &dest[i]; } char* -strncpy(char* dest, const char* src, size_t n) +strncpy(char* dest, const char* src, unsigned long n) { char c; unsigned int i = 0;