string.h

The header file contains prototypes for functions that manipulate strings in main memory. They are similar to those in memory.h, but are more extensive and use the 'C' convention of a NUL terminated string in an array of "char". These functions are:

    strcat()    strcspn()    strlwr()     strpbrk()    strspn()
    strchr()    strdup()     strncat()    strrchr()    strstr()
    strcmp()    strerror()   strncmp()    strrev()     strtok()
    strcmpi()   stricmp()    strnicmp()   strset()     strupr()
    strcpy()    strlen()     strnset()    strspn()

These functions append, search, compare, copy, duplicate, find length, initialize, reverse, change case, and find tokens in strings.

The function strncpy() is flawed - it does guarantee to put a null char at the destination array and it wastes time zero filling if teh source is shorter the the destination.


© 1991-2008 Prem Sobel. All Rights Reserved.