| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
with ``__'' to avoid polluting the namespace. This doesn't change the
documented rune interface at all, but breaks applications that accessed
_RuneLocale directly.
|
|
|
|
|
| |
mbsrtowcs() and wcsrtombs(). Provide a fast implementation for the
trivial "NONE" encoding.
|
|
|
|
| |
file to avoid extern'ing them all over the place.
|
|
|
|
|
| |
objects passed to mbrtowc(), mbsrtowcs(), and mbrlen(), as required
by C99.
|
|
|
|
| |
old rune interface now that it is no longer needed.
|
|
|
|
|
|
|
| |
Save __mbrtowc and __wcrtomb and restore them when changing back to
the cached locale.
Reported by: perky
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
as wrappers around the deprecated 4.4BSD rune functions. This paves the
way for state-dependent encodings, which the rune API does not support.
- Add __emulated_sgetrune() and __emulated_sputrune(), which are
implementations of sgetrune() and sputrune() in terms of
mbrtowc() and wcrtomb().
- Rename the old rune-wrapper mbrtowc() and wcrtomb() functions to
__emulated_mbrtowc() and __emulated_wcrtomb().
- Add __mbrtowc and __wcrtomb function pointers, which point to the
current locale's conversion functions, or the __emulated versions.
- Implement mbrtowc() and wcrtomb() as calls to these function pointers.
- Make the "NONE" encoding implement mbrtowc() and wcrtomb() directly.
All of this emulation mess will be removed, together with rune support,
in FreeBSD 6.
|
|
|
|
|
| |
PR: 51729
Submitted by: Kang Liu <liukang@bjpu.edu.cn>
|
| |
|
|
|
|
| |
in FreeBSD 6
|
|
|
|
| |
internal helper function.
|
|
|
|
|
| |
PR: 51504
Submitted by: Statue <statue@freebsd.sinica.edu.tw>
|
|
|
|
|
|
|
| |
"UTF2" method. Although UTF-8 and the old UTF2 encoding are compatible
for 16-bit characters, the new UTF-8 implementation is much more strict
about rejecting malformed input and also handles the full 31 bit range
of characters.
|
| |
|
|
|
|
|
|
|
|
| |
currently cached data. It allows a number of nice things, like: removing
fallback code from single locale loading, remove memory leak when LC_CTYPE
data loaded again and again, efficient cache use, not only for
setlocale(locale1); setlocale(locale1), but for setlocale(locale1);
setlocale("C"); setlocale(locale1) too (i.e. data file loaded only once).
|
| |
|
| |
|
|
|
|
|
| |
Return EFTYPE instead of EINVAL for wrong locale file format.
Whitespaces.
|
| |
|
| |
|
| |
|
|
|
|
| |
I believe have made all of libc .c's as consistent as possible.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
the diff is attached below. This is done on the 3.0 source-tree.
I have test this on 2.2-stable before, but I don't have a 3.0 machine
right now.
This patch is mainly to make libc support BIG5 encoding, thus add
zh_TW.BIG5 locale to 3.0.
Submitted by: Chen Hsiung Chan <frankch@waru.life.nthu.edu.tw>
|
|
|
|
| |
do not exist in NetBSD 1.3.
|
| |
|
|
|
|
|
| |
Basic support for the Shift JIS encoding of japanese.
(and one tiny typo fixed in a comment)
|
| |
|
|
|
|
|
|
|
|
| |
Add range check for setrunelocale since it can be called
directly.
Remove _startup_setlocale compatibility function
Should go into 2.2
|
|
|
|
|
|
|
| |
Fix setrunelocale fail if called directly without prior setlocale
call
Should go in 2.2
|
|
|
|
|
|
| |
Kill snprintf left in collate.c from previous backout
Should go in 2.2
|
| |
|
|
|
|
|
|
|
|
| |
Vulnerable: all programs that use setlocale(LC_COLLATE),
setlocale(LC_CTYPE), or setlocale(LC_ALL). The only setuid/setgid
binary i've found for this is w(1).
Should go into 2.2.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
strdup() it to prevent unsetenv() or setenv() effects. Check its length to
not allow user to overflow internal locale buffer. Move PATH_LOCALE
handling code into one place.
POSIX: make better stub for LC_MONETARY & LC_NUMERIC, now it check
locale directory existance instead of refusing all non-C non-POSIX
locales. POSIX treats empty locale env variable as unset variable
while our old code treats it as "C" locale, fix it. Implement previous locale
restoring, if locale setting fails. Old code assumes success if some
of LC_ALL subset is successed even other fails, POSIX treats it as
failure with previous locale restoring, fix it.
Remove unneccessary length checking in currentlocale()
|
|
|
|
| |
Handle negative chars inside runetype/tolower/toupper
|
| |
|
|
Remove big part of my startup_setlocale hack.
Add missing manpage links.
|