summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac4
-rw-r--r--utils.c31
-rw-r--r--utils.h6
3 files changed, 2 insertions, 39 deletions
diff --git a/configure.ac b/configure.ac
index 5f3473a..0cbfc40 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
# Initialize Autoconf
AC_PREREQ([2.60])
-AC_INIT([xkbutils], [1.0.5],
+AC_INIT([xkbutils], [1.0.6],
[https://gitlab.freedesktop.org/xorg/app/xkbutils/issues], [xkbutils])
AC_CONFIG_SRCDIR([Makefile.am])
AC_CONFIG_HEADERS([config.h])
@@ -38,8 +38,6 @@ m4_ifndef([XORG_MACROS_VERSION],
XORG_MACROS_VERSION(1.8)
XORG_DEFAULT_OPTIONS
-AC_CHECK_FUNCS([strcasecmp])
-
# xkbvleds checks
PKG_CHECK_MODULES(XKBVLEDS, [xproto >= 7.0.17 xaw7 xt x11])
diff --git a/utils.c b/utils.c
index 6a1f432..b29576f 100644
--- a/utils.c
+++ b/utils.c
@@ -123,34 +123,3 @@ uInternalError(const char *s, ...)
va_end(ap);
return;
}
-
-/***====================================================================***/
-
-#ifndef HAVE_STRCASECMP
-int
-uStrCaseCmp(const char *str1, const char *str2)
-{
- char buf1[512], buf2[512];
- char c, *s;
-
- register int n;
-
- for (n = 0, s = buf1; (c = *str1++); n++) {
- if (isupper(c))
- c = tolower(c);
- if (n > 510)
- break;
- *s++ = c;
- }
- *s = '\0';
- for (n = 0, s = buf2; (c = *str2++); n++) {
- if (isupper(c))
- c = tolower(c);
- if (n > 510)
- break;
- *s++ = c;
- }
- *s = '\0';
- return (strcmp(buf1, buf2));
-}
-#endif
diff --git a/utils.h b/utils.h
index a79019d..732f2e7 100644
--- a/utils.h
+++ b/utils.h
@@ -39,6 +39,7 @@
#include <X11/Xfuncs.h>
#include <stdarg.h>
#include <stddef.h>
+#include <strings.h>
_XFUNCPROTOBEGIN
@@ -65,12 +66,7 @@ extern void uInternalError(const char *s, ...) _X_ATTRIBUTE_PRINTF(1,2);
/***====================================================================***/
#define uStrCaseEqual(s1,s2) (uStrCaseCmp(s1,s2)==0)
-#ifdef HAVE_STRCASECMP
#define uStrCaseCmp(s1,s2) (strcasecmp(s1,s2))
-#else
-extern int uStrCaseCmp(const char * /* s1 */,
- const char * /* s2 */);
-#endif
/***====================================================================***/