This is the mail archive of the libc-alpha@sources.redhat.com mailing list for the glibc project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
On Sun, 2002-04-21 at 02:30, Paolo Carlini wrote:
> if (__len)
> {
> ++__len;
> memset(&__state, 0, sizeof(mbstate_t));
> wchar_t* __wcs = (wchar_t*) malloc(sizeof(wchar_t) * __len);
> __len2 = mbsrtowcs(__wcs, &__ccurr, __len, &__state);
> _M_curr_symbol = __wcs;
> }
You cannot use mbsrtwcs here. The locale which is used for it is the
"C" locale which doesn't know any non-ASCII characters.
Either you add
setlocale (LC_ALL, _s);
before the mbsrtowcs call or you wait until the uselocale function is
implemented and use that.
--
---------------. ,-. 1325 Chesapeake Terrace
Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
Red Hat `--' drepper at redhat.com `------------------------
Attachment:
signature.asc
Description: This is a digitally signed message part
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |