diff options
author | Ulrich Drepper <drepper@redhat.com> | 1999-07-28 19:37:40 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 1999-07-28 19:37:40 +0000 |
commit | 9f097308c7465443765d1e25699a4cf33eff5455 (patch) | |
tree | f78dbcef1a0e630554b6d9e299c9767740d86485 /stdlib/wctomb.c | |
parent | 97a0d44d89e7724e104f3de8450112712767ec90 (diff) | |
download | glibc-9f097308c7465443765d1e25699a4cf33eff5455.tar.gz |
Update.
1999-07-28 Ulrich Drepper <drepper@cygnus.com>
* stdlib/mblen.c: Use static state.
Reported by Bruno Haible <haible@ilog.fr>.
* stdlib/mbtowc.c: Reset state for s == NULL.
* stdlib/wctomb.c: Likewise.
Reported by Bruno Haible <haible@ilog.fr>.
* stdlib/mbstowcs.c: Do not use global state.
Reported by Bruno Haible <haible@ilog.fr>.
Diffstat (limited to 'stdlib/wctomb.c')
-rw-r--r-- | stdlib/wctomb.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/stdlib/wctomb.c b/stdlib/wctomb.c index 2df8b998d5..757e6adaad 100644 --- a/stdlib/wctomb.c +++ b/stdlib/wctomb.c @@ -42,6 +42,10 @@ wctomb (char *s, wchar_t wchar) /* Make sure we use the correct value. */ update_conversion_ptrs (); + /* This is an extension in the Unix standard which does not directly + violate ISO C. */ + memset (&__no_r_state, '\0', siyeof __no_r_state); + return __wcsmbs_gconv_fcts.tomb->__stateful; } |