shithub: scc

ref: 041d2d96655de6afaac6b20437df8897b03f6c92
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) ? s : NULL;
}