ref: 0c5f7ed72475e2aef74aa672bab0d3a39dee2ecb dir: /lib/c/strchr.c/
#include <string.h> #undef strchr char * strchr(const char *s, int c) { while (*s && *s != c) ++s; return (*s == c) ? (char *)s : NULL; }