X-Git-Url: https://pd.if.org/git/?p=pdclib.old;a=blobdiff_plain;f=functions%2Fwctype%2Ftowupper.c;h=7b96a6100b964b322105e0617f634ee7664d5bc6;hp=faac657501cac24ec24b262673befcdb97f5713f;hb=b3d54170225e25557110b8c74f236b5e84254c26;hpb=24f274eec4d6ac3868f3fdf03d2e1876c80be616 diff --git a/functions/wctype/towupper.c b/functions/wctype/towupper.c index faac657..7b96a61 100644 --- a/functions/wctype/towupper.c +++ b/functions/wctype/towupper.c @@ -8,10 +8,10 @@ #ifndef REGTEST #include <_PDCLIB_locale.h> -wint_t towupper( wint_t wc ) +wint_t _PDCLIB_towupper_l( wint_t wc, locale_t l ) { wint_t uwc = _PDCLIB_unpackwint( wc ); - _PDCLIB_wcinfo_t *info = _PDCLIB_wcgetinfo( uwc ); + _PDCLIB_wcinfo_t *info = _PDCLIB_wcgetinfo( l, uwc ); if( info && info->upper != uwc ) { wc = info->upper; @@ -19,6 +19,11 @@ wint_t towupper( wint_t wc ) return wc; } +wint_t towupper( wint_t wc ) +{ + return _PDCLIB_towupper_l( wc, _PDCLIB_threadlocale() ); +} + #endif #ifdef TEST