ref: 5e809c5e93c43d9fe8c2829f91651eb341e5e58e
dir: /lib/c/strrchr.c/
#include <string.h>
#undef strrchr
char *
strrchr(const char *s, int c)
{
const char *t = s;
while (*t)
++t;
while (t > s && *t != c)
--t;
return (*t == c) ? (char *)t : NULL;
}