welibc
A clear, secure, and well documented standard C library
Functions
strpbrk.c File Reference

Defines the strpbrk function. More...

#include <string.h>
Include dependency graph for strpbrk.c:

Go to the source code of this file.

Functions

char * strpbrk (const char *s1, const char *s2)
 Locate the first occurrence of any of s2 in s1. More...
 

Detailed Description

Defines the strpbrk function.

Definition in file strpbrk.c.

Function Documentation

◆ strpbrk()

char* strpbrk ( const char *  s1,
const char *  s2 
)

Locate the first occurrence of any of s2 in s1.

Parameters
*s1String being searched
*s2String of characters to search for

The strpbrk function locates the first occurrence in the string pointed to by s1 of any character from the string pointed to by s2.

Returns
A pointer to the character, or NULL if no character was found

Definition at line 51 of file strpbrk.c.

References NULL, and strcspn().

Here is the call graph for this function: