mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-09-21 05:26:20 +02:00
Merge branch 'bug26594'
This commit is contained in:
commit
d88ce331ef
@ -610,6 +610,8 @@ AC_CHECK_FUNCS(
|
|||||||
sigaction \
|
sigaction \
|
||||||
socketpair \
|
socketpair \
|
||||||
statvfs \
|
statvfs \
|
||||||
|
strncasecmp \
|
||||||
|
strcasecmp \
|
||||||
strlcat \
|
strlcat \
|
||||||
strlcpy \
|
strlcpy \
|
||||||
strnlen \
|
strnlen \
|
||||||
|
@ -13,9 +13,20 @@
|
|||||||
|
|
||||||
/* ===== String compatibility */
|
/* ===== String compatibility */
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
/* Windows names string functions differently from most other platforms. */
|
/* Windows doesn't have str(n)casecmp, but mingw defines it: only define it
|
||||||
#define strncasecmp _strnicmp
|
* ourselves if it's missing. */
|
||||||
#define strcasecmp _stricmp
|
#ifndef HAVE_STRNCASECMP
|
||||||
|
static inline int strncasecmp(const char *a, const char *b, size_t n);
|
||||||
|
static inline int strncasecmp(const char *a, const char *b, size_t n) {
|
||||||
|
return strncmpi(a,b);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
#ifndef HAVE_STRCASECMP
|
||||||
|
static inline int strcasecmp(const char *a, const char *b, size_t n);
|
||||||
|
static inline int strcasecmp(const char *a, const char *b, size_t n) {
|
||||||
|
return strcmpi(a,b);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined __APPLE__
|
#if defined __APPLE__
|
||||||
|
Loading…
Reference in New Issue
Block a user