shithub: scc

ref: e9c7dc18d0822fb48455be3bcc96b9eca6c8a142
dir: /lib/c/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;
}