diff options
Diffstat (limited to 'newlib/libc/stdlib/wctomb.c')
-rw-r--r-- | newlib/libc/stdlib/wctomb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/newlib/libc/stdlib/wctomb.c b/newlib/libc/stdlib/wctomb.c index a6812508f..5cff10fff 100644 --- a/newlib/libc/stdlib/wctomb.c +++ b/newlib/libc/stdlib/wctomb.c @@ -54,9 +54,9 @@ _DEFUN (wctomb, (s, wchar), wchar_t wchar) { #ifdef MB_CAPABLE - static int state; + _REENT_CHECK_MISC(_REENT); - return _wctomb_r (_REENT, s, wchar, &state); + return _wctomb_r (_REENT, s, wchar, &(_REENT_WCTOMB_STATE(_REENT))); #else /* not MB_CAPABLE */ if (s == NULL) return 0; |