From fd63f744f7e33294051bf12c622a50d99e64c9ca Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Mon, 24 Jul 2017 19:54:32 +0200 Subject: [PATCH] mescc: Tinycc support: strstr stub. * mlibc/include/string.h (strstr): Declare. * mlibc/libc-mes+tcc.c (strstr): Add stub. --- mlibc/include/string.h | 1 + mlibc/libc-mes+tcc.c | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/mlibc/include/string.h b/mlibc/include/string.h index 4d706a7b..48f5e466 100644 --- a/mlibc/include/string.h +++ b/mlibc/include/string.h @@ -50,6 +50,7 @@ int strcmp (char const*, char const*); char *strcpy (char *dest, char const *src); int strncmp (char const*, char const*, size_t); char *strrchr (char const *s, int c); +char *strstr (char const *haystack, char const *needle); #endif // ! (__GNUC__ && POSIX) diff --git a/mlibc/libc-mes+tcc.c b/mlibc/libc-mes+tcc.c index f038949b..19353555 100644 --- a/mlibc/libc-mes+tcc.c +++ b/mlibc/libc-mes+tcc.c @@ -172,6 +172,12 @@ strrchr (char const *s, int c) return 0; } +char * +strstr (char const *haystack, char const *needle) +{ + return 0; +} + long strtol (char const *nptr, char **endptr, int base) {