ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

mbslwr.c
Go to the documentation of this file.
00001 /*
00002  * COPYRIGHT:   See COPYING in the top level directory
00003  * PROJECT:     ReactOS system libraries
00004  * FILE:        lib/sdk/crt/mbstring/mbslwr.c
00005  * PURPOSE:     Multibyte lowercase functions
00006  * PROGRAMER:   Eric Kohl
00007  *              Samuel Serapion, adapted from PROJECT C Library
00008  */
00009 
00010 #include <precomp.h>
00011 #include <mbstring.h>
00012 #include <ctype.h>
00013 
00014 unsigned int _mbbtolower(unsigned int c)
00015 {
00016     if (!_ismbblead(c) )
00017         return tolower(c);
00018     return c;
00019 }
00020 
00021 /*
00022  * @implemented
00023  */
00024 unsigned int _mbctolower(unsigned int c)
00025 {
00026     return _ismbcupper (c) ? c + 0x21 : c;
00027 }
00028 
00029 /*
00030  * @implemented
00031  */
00032 unsigned char * _mbslwr(unsigned char *x)
00033 {
00034     unsigned char *y=x;
00035 
00036     if (x == NULL)
00037     {
00038         return NULL;
00039     }
00040 
00041     while (*y) 
00042     {
00043         if (!_ismbblead(*y)) 
00044         {
00045             *y = tolower(*y);
00046             y++;
00047         } 
00048         else
00049         {
00050             *y = _mbctolower(*(unsigned short *)y);
00051             y++;
00052         }
00053     }
00054     return x;
00055 }

Generated on Mon May 28 2012 04:36:17 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.