about summary refs log tree commit diff
path: root/localedata/tests-mbwc/tst_mbtowc.c
diff options
context:
space:
mode:
Diffstat (limited to 'localedata/tests-mbwc/tst_mbtowc.c')
-rw-r--r--localedata/tests-mbwc/tst_mbtowc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/localedata/tests-mbwc/tst_mbtowc.c b/localedata/tests-mbwc/tst_mbtowc.c
index c525941f60..7c274f66c1 100644
--- a/localedata/tests-mbwc/tst_mbtowc.c
+++ b/localedata/tests-mbwc/tst_mbtowc.c
@@ -49,6 +49,10 @@ tst_mbtowc (FILE * fp, int debug_flg)
 
 	wp = (wchar_t *) ((w_flg == 0) ? NULL : &wc);
 
+	/* XXX Clear the internal state.  We should probably have
+	   a flag for this.  */
+	mbtowc (NULL, NULL, 0);
+
 	TST_CLEAR_ERRNO;
 	ret = mbtowc (wp, s_in, n);
 	TST_SAVE_ERRNO;