backported fixes from 256boss
[bootcensus] / src / libc / string.h
index 63bb299..85490b2 100644 (file)
@@ -1,6 +1,6 @@
 /*
 pcboot - bootable PC demo/game kernel
 /*
 pcboot - bootable PC demo/game kernel
-Copyright (C) 2018  John Tsiombikas <nuclear@member.fsf.org>
+Copyright (C) 2018-2019  John Tsiombikas <nuclear@member.fsf.org>
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
@@ -20,19 +20,33 @@ along with this program.  If not, see <https://www.gnu.org/licenses/>.
 
 #include <stdlib.h>
 
 
 #include <stdlib.h>
 
-void memset(void *s, int c, size_t n);
-void memset16(void *s, int c, size_t n);
+void *memset(void *s, int c, size_t n);
+void *memset16(void *s, int c, size_t n);
 
 void *memcpy(void *dest, const void *src, size_t n);
 void *memmove(void *dest, const void *src, size_t n);
 
 
 void *memcpy(void *dest, const void *src, size_t n);
 void *memmove(void *dest, const void *src, size_t n);
 
+int memcmp(void *aptr, void *bptr, size_t n);
+
 size_t strlen(const char *s);
 
 char *strchr(const char *s, int c);
 char *strrchr(const char *s, int c);
 
 char *strstr(const char *str, const char *substr);
 size_t strlen(const char *s);
 
 char *strchr(const char *s, int c);
 char *strrchr(const char *s, int c);
 
 char *strstr(const char *str, const char *substr);
+char *strcasestr(const char *str, const char *substr);
 
 int strcmp(const char *s1, const char *s2);
 
 int strcmp(const char *s1, const char *s2);
+int strcasecmp(const char *s1, const char *s2);
+
+int strncmp(const char *s1, const char *s2, int n);
+int strncasecmp(const char *s1, const char *s2, int n);
+
+char *strcpy(char *dest, const char *src);
+char *strcat(char *dest, const char *src);
+
+char *strncpy(char *dest, const char *src, int n);
+
+char *strerror(int err);
 
 #endif /* STRING_H_ */
 
 #endif /* STRING_H_ */