summaryrefslogtreecommitdiff
path: root/libc
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2006-01-03 15:48:34 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2006-01-03 15:48:34 +0000
commitfbf868b243b07b0e91e8da11086bc172d7c146da (patch)
treef8dac52d97fce8a94d3f3c57d669364a31d5cada /libc
parentb3250689637e8e07ae563cf97e5e85386d069228 (diff)
Provide __tolower and use it
Diffstat (limited to 'libc')
-rw-r--r--libc/misc/ctype/ctype.c7
-rw-r--r--libc/string/strcasecmp.c2
-rw-r--r--libc/string/strncasecmp.c2
3 files changed, 7 insertions, 4 deletions
diff --git a/libc/misc/ctype/ctype.c b/libc/misc/ctype/ctype.c
index 60301d48c..c53979e23 100644
--- a/libc/misc/ctype/ctype.c
+++ b/libc/misc/ctype/ctype.c
@@ -268,9 +268,11 @@ IS_FUNC_BODY(xdigit);
/**********************************************************************/
#ifdef L_tolower
+#undef tolower
+#undef __tolower
#ifdef __UCLIBC_HAS_CTYPE_TABLES__
-int tolower(int c)
+int attribute_hidden __tolower(int c)
{
#if defined(__UCLIBC_HAS_CTYPE_ENFORCED__)
assert(CTYPE_DOMAIN_CHECK(c));
@@ -280,12 +282,13 @@ int tolower(int c)
#else /* __UCLIBC_HAS_CTYPE_TABLES__ */
-int tolower(int c)
+int attribute_hidden __tolower(int c)
{
return __C_tolower(c);
}
#endif /* __UCLIBC_HAS_CTYPE_TABLES__ */
+strong_alias(__tolower,tolower)
#endif
/**********************************************************************/
diff --git a/libc/string/strcasecmp.c b/libc/string/strcasecmp.c
index 054bc01ae..1d758e2ca 100644
--- a/libc/string/strcasecmp.c
+++ b/libc/string/strcasecmp.c
@@ -32,7 +32,7 @@ extern wint_t __towlower_l (wint_t __wc, __locale_t __locale) __THROW attribute_
# ifdef __UCLIBC_DO_XLOCALE
# define TOLOWER(C) __tolower_l((C), locale_arg)
# else
-# define TOLOWER(C) tolower((C))
+# define TOLOWER(C) __tolower((C))
# endif
#endif
diff --git a/libc/string/strncasecmp.c b/libc/string/strncasecmp.c
index 96f31cabd..bfc865a8c 100644
--- a/libc/string/strncasecmp.c
+++ b/libc/string/strncasecmp.c
@@ -32,7 +32,7 @@ extern wint_t __towlower_l (wint_t __wc, __locale_t __locale) __THROW attribute_
# ifdef __UCLIBC_DO_XLOCALE
# define TOLOWER(C) __tolower_l((C), locale_arg)
# else
-# define TOLOWER(C) tolower((C))
+# define TOLOWER(C) __tolower((C))
# endif
#endif