MEMCHR(3) Library Functions Manual MEMCHR(3)
NAME
memchr — find byte
in memory
SYNOPSIS
#include <string.h> void *memchr(const void *s, int c, size_t n);
DESCRIPTION
The memchr() function locates the first occurrence of c (converted to an unsigned char ) in the initial n bytes (each interpreted as unsigned char ) of the object pointed to by s .
RETURN VALUE
The memchr() function returns a pointer to the located byte, or a null pointer if the byte does not occur in the object.
ERRORS
No errors are defined.
EXAMPLES
None.
APPLICATION USAGE
None.
FUTURE DIRECTIONS
None.
SEE ALSO
DERIVATION
Derived from Issue 1 of the SVID.
February 1997 posix.fail