ref: fe1c4b0df744e9773a52356baaa91024c8e83e31
dir: /doc/man3/memchr.3/
.TH memchr 3 .SH NAME memchr - find byte in memory .SH SYNOPSIS #include <string.h> void *memchr(const void *s, int c, size_t n) .SH DESCRIPTION The .BR memchr () function locates the first occurence of .I c (converted to an unsigned char) in the initial .I n characters (each interpreted as unsigned char) of the object pointed to by .IR s . .PP The function shall not try to locate .I c if .I n is equal to 0. .SH RETURN VALUE The .BR memchr () function shall return a pointer to the located character or a null pointer if the character does not occur in the object. .SH STANDARDS ISO/IEC 9899:1999 Section 7.21.5.1