ref: f3d06fb5d6fc6d3540f693f883c90c50141fc6f1 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; }