This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH v3 2/2] Port strnstr.c to newlib.


---
 newlib/libc/include/string.h   | 3 +++
 newlib/libc/string/Makefile.am | 1 +
 2 files changed, 4 insertions(+)

diff --git a/newlib/libc/include/string.h b/newlib/libc/include/string.h
index 7833aa1..9c536f3 100644
--- a/newlib/libc/include/string.h
+++ b/newlib/libc/include/string.h
@@ -121,6 +121,9 @@ size_t	 _EXFUN(strnlen,(const char *, size_t));
 #if __BSD_VISIBLE
 char 	*_EXFUN(strsep,(char **, const char *));
 #endif
+#if __BSD_VISIBLE
+char    *strnstr(const char *, const char *, size_t) __pure;
+#endif
 
 #if __MISC_VISIBLE
 char	*_EXFUN(strlwr,(char *));
diff --git a/newlib/libc/string/Makefile.am b/newlib/libc/string/Makefile.am
index e62f286..f8bd41e 100644
--- a/newlib/libc/string/Makefile.am
+++ b/newlib/libc/string/Makefile.am
@@ -40,6 +40,7 @@ GENERAL_SOURCES = \
 	strncmp.c \
 	strncpy.c \
 	strnlen.c \
+	strnstr.c \
 	strpbrk.c \
 	strrchr.c \
 	strsep.c \
-- 
2.7.4




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]