diff options
author | bapt <bapt@FreeBSD.org> | 2015-10-19 14:30:28 +0000 |
---|---|---|
committer | bapt <bapt@FreeBSD.org> | 2015-10-19 14:30:28 +0000 |
commit | d3438cfcadabee8093facc0919d9a8165044bcf9 (patch) | |
tree | 5cbe253186dfcb3f6fb2db1f4759b7996aa5ef63 /usr.bin/localedef | |
parent | d93a51152871c391e2ff845cfd568a72cef65606 (diff) | |
download | FreeBSD-src-d3438cfcadabee8093facc0919d9a8165044bcf9.zip FreeBSD-src-d3438cfcadabee8093facc0919d9a8165044bcf9.tar.gz |
With regard to ctype, digits (e.g. 0 to 9) and xdigits (the 0 to 9 portion
of hexidecimal numbers) are all considered "numbers". (Note that while
all digits are numbers, not all numbers are digits).
Enhance localedef to automatically set the "number" characteristic when
it encounters a digit or xdigit definition. This fixes malfunctionning
isalnum(3)
Obtained from: DragonflyBSD
Diffstat (limited to 'usr.bin/localedef')
-rw-r--r-- | usr.bin/localedef/ctype.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/localedef/ctype.c b/usr.bin/localedef/ctype.c index a28cdf2..36f5829 100644 --- a/usr.bin/localedef/ctype.c +++ b/usr.bin/localedef/ctype.c @@ -117,7 +117,7 @@ add_ctype_impl(ctype_node_t *ctn) ctn->ctype |= (_ISALPHA | _ISGRAPH | _ISPRINT); break; case T_ISDIGIT: - ctn->ctype |= (_ISDIGIT | _ISGRAPH | _ISPRINT | _ISXDIGIT); + ctn->ctype |= (_ISDIGIT | _ISGRAPH | _ISPRINT | _ISXDIGIT | _E4); break; case T_ISSPACE: ctn->ctype |= _ISSPACE; @@ -135,7 +135,7 @@ add_ctype_impl(ctype_node_t *ctn) ctn->ctype |= (_ISPUNCT | _ISGRAPH | _ISPRINT); break; case T_ISXDIGIT: - ctn->ctype |= (_ISXDIGIT | _ISPRINT); + ctn->ctype |= (_ISXDIGIT | _ISPRINT | _E4); break; case T_ISBLANK: ctn->ctype |= (_ISBLANK | _ISSPACE); |