shithub: scc

ref: 15d3cccf394c8c68e3d6e8311c3b50910ad23f91
dir: /src/libc/string/strchr.c/

View raw version
#include <string.h>
#undef strchr

char *
strchr(const char *s, int c)
{
	while (*s && *s != c)
		++s;
	return (*s == c) ? (char *)s : NULL;
}