[OpenBIOS] [commit] r747 - in trunk/openbios-devel: include/libc libc
repository service
svn at openbios.org
Thu Apr 15 18:43:02 CEST 2010
Author: blueswirl
Date: Thu Apr 15 18:43:01 2010
New Revision: 747
URL: http://tracker.coreboot.org/trac/openbios/changeset/747
Log:
Remove unused memchr()
Signed-off-by: Blue Swirl <blauwirbel at gmail.com>
Modified:
trunk/openbios-devel/include/libc/string.h
trunk/openbios-devel/libc/string.c
Modified: trunk/openbios-devel/include/libc/string.h
==============================================================================
--- trunk/openbios-devel/include/libc/string.h Thu Apr 15 18:42:59 2010 (r746)
+++ trunk/openbios-devel/include/libc/string.h Thu Apr 15 18:43:01 2010 (r747)
@@ -43,7 +43,6 @@
extern void *memcpy(void * dest,const void *src,size_t count);
extern void *memmove(void * dest,const void *src,size_t count);
extern int memcmp(const void * cs,const void * ct,size_t count);
-extern void *memchr(const void *s, int c, size_t n);
extern char *strdup( const char *str );
extern int strcasecmp( const char *cs, const char *ct );
Modified: trunk/openbios-devel/libc/string.c
==============================================================================
--- trunk/openbios-devel/libc/string.c Thu Apr 15 18:42:59 2010 (r746)
+++ trunk/openbios-devel/libc/string.c Thu Apr 15 18:43:01 2010 (r747)
@@ -346,27 +346,6 @@
return res;
}
-/**
- * memchr - Find a character in an area of memory.
- * @s: The memory area
- * @c: The byte to search for
- * @n: The size of the area.
- *
- * returns the address of the first occurrence of @c, or %NULL
- * if @c is not found
- */
-void *memchr(const void *s, int c, size_t n)
-{
- const unsigned char *p = s;
- while (n-- != 0) {
- if ((unsigned char)c == *p++) {
- return (void *)(p-1);
- }
- }
- return NULL;
-}
-
-
char *
strdup( const char *str )
{
More information about the OpenBIOS
mailing list