shithub: scc

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