shithub: scc

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