welibc
A clear, secure, and well documented standard C library
|
Defines the strchr function. More...
#include <string.h>
Go to the source code of this file.
Functions | |
char * | strchr (const char *s, int c) |
Locate the first occurrence of a character in a string. More... | |
Defines the strchr function.
Definition in file strchr.c.
char* strchr | ( | const char * | s, |
int | c | ||
) |
Locate the first occurrence of a character in a string.
*s | String being searched |
c | Character to find |
The strchr function locates the first occurrence of c (converted to a char) in the string pointed to by s. The terminating null character is considered to be a part of the string.
NULL | The character does not occur in the string |
Definition at line 53 of file strchr.c.
References NULL.
Referenced by strcspn(), strspn(), and strstr().