forked from PoliEcho-holding-org/kern
Changed libc structure, shouldn't've added anything new
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
#include <string.h>
|
||||
|
||||
char* strcat(char* str1, const char* str2) {
|
||||
char* s = str1;
|
||||
while (*s != '\0') { s++; }
|
||||
strcpy(s, str2);
|
||||
return str1;
|
||||
}
|
||||
|
||||
char* strncat(char* str1, const char* str2, size_t n) {
|
||||
char* s = str1;
|
||||
while (*s != '\0') { s++; }
|
||||
strncpy(s, str2, n);
|
||||
return str1;
|
||||
}
|
||||
Reference in New Issue
Block a user