aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/stdlib/mblen.c
diff options
context:
space:
mode:
Diffstat (limited to 'newlib/libc/stdlib/mblen.c')
-rw-r--r--newlib/libc/stdlib/mblen.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/newlib/libc/stdlib/mblen.c b/newlib/libc/stdlib/mblen.c
index 3753d36..24df615 100644
--- a/newlib/libc/stdlib/mblen.c
+++ b/newlib/libc/stdlib/mblen.c
@@ -42,6 +42,10 @@ effects vary with the locale.
#include <wchar.h>
#include "local.h"
+#ifdef _REENT_THREAD_LOCAL
+_Thread_local _mbstate_t _tls_mblen_state;
+#endif
+
int
mblen (const char *s,
size_t n)