]> granicus.if.org Git - php/commitdiff
there is no realiable way to detect memrchr() presence because of a mess in glibc
authorAntony Dovgal <tony2001@php.net>
Tue, 8 Aug 2006 10:54:24 +0000 (10:54 +0000)
committerAntony Dovgal <tony2001@php.net>
Tue, 8 Aug 2006 10:54:24 +0000 (10:54 +0000)
so let's use our own implementation

Zend/zend_operators.h
configure.in

index 82743324177ecbeed3184ca0e90a1e6251e8ac73..c7c3991d572f864fff7c65e09532c0db8c321060 100644 (file)
@@ -169,16 +169,6 @@ zend_memnstr(char *haystack, char *needle, int needle_len, char *end)
        return NULL;
 }
 
-#ifdef HAVE_MEMRCHR
-# ifndef __USE_GNU
-#  define __USE_GNU
-# endif
-
-#include <string.h>
-#define zend_memrchr memrchr
-
-#else
-
 static inline void *zend_memrchr(const void *s, int c, size_t n)
 {
        register unsigned char *e = (unsigned char *)s + n;
@@ -191,7 +181,6 @@ static inline void *zend_memrchr(const void *s, int c, size_t n)
 
        return NULL;
 }
-#endif
 
 BEGIN_EXTERN_C()
 ZEND_API int increment_function(zval *op1);
index 242b25ab2eeff7b98e273cf7f5564a9737e28626..f9df4138650e26c83f73a903a8525d3e7d755b15 100644 (file)
@@ -491,7 +491,6 @@ lchown \
 lrand48 \
 memcpy \
 memmove \
-memrchr \
 mkstemp \
 mmap \
 nl_langinfo \