SDDSlib
Loading...
Searching...
No Matches
str_toupper.c File Reference

Implementation of the str_toupper function. More...

#include "mdb.h"
#include <ctype.h>

Go to the source code of this file.

Functions

char * str_toupper (char *s)
 Convert a string to upper case.
 

Detailed Description

Implementation of the str_toupper function.

License
This file is distributed under the terms of the Software License Agreement found in the file LICENSE included with this distribution.
Author
M. Borland, C. Saunders, R. Soliday

Definition in file str_toupper.c.

Function Documentation

◆ str_toupper()

char * str_toupper ( char * s)

Convert a string to upper case.

This function takes a string and converts all its characters to upper case.

Parameters
sThe string to convert.
Returns
The converted string.

Definition at line 27 of file str_toupper.c.

28{
29 register char *ptr;
30
31 ptr = s;
32 while (*ptr) {
33 *ptr = toupper(*ptr);
34 ptr++;
35 }
36 return (s);
37}