source: umon/main/glib/strtolower.c @ b987a75

Last change on this file since b987a75 was b987a75, checked in by Jarielle Catbagan <jcatbagan93@…>, on Jun 19, 2015 at 9:32:43 PM

Removed execution mode file attribute from all ASCII text files

  • Property mode set to 100644
File size: 414 bytes
Line 
1#include "config.h"
2#include <ctype.h>
3#include "genlib.h"
4#include "stddefs.h"
5
6/* strtolower():
7 *      In-place modification of a string to be all lower case.
8 */
9char *
10strtolower(char *string)
11{
12        char *cp;
13
14        cp = string;
15        while(*cp) {
16                *cp = tolower(*cp);
17                cp++;
18        }
19        return(string);
20}
21
22char *
23strtoupper(char *string)
24{
25        char *cp;
26
27        cp = string;
28        while(*cp) {
29                *cp = toupper(*cp);
30                cp++;
31        }
32        return(string);
33}
Note: See TracBrowser for help on using the repository browser.