X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=functions%2Fctype%2Ftolower.c;h=a77001ef8e687fdbbddd10209e8d9fc94f9b1690;hb=ed01ab8d9fcc47f6a4089ef72a73ef7a084d1ed3;hp=28c435ded8377d125f49ece8b5a8c8b2767007d4;hpb=eb9211f1090ef05e8490a6b35acbe16c9ed9f89a;p=pdclib.old diff --git a/functions/ctype/tolower.c b/functions/ctype/tolower.c index 28c435d..a77001e 100644 --- a/functions/ctype/tolower.c +++ b/functions/ctype/tolower.c @@ -9,14 +9,11 @@ #include #ifndef REGTEST +#include <_PDCLIB_locale.h> int tolower( int c ) { - if ( ( c >= 'A' ) && ( c <= 'Z' ) ) - { - c += ( 'a' - 'A' ); - } - return c; + return _PDCLIB_threadlocale()->_CType[c].lower; } #endif