shithub: scc

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