aboutsummaryrefslogtreecommitdiff
path: root/src/string/wcsrchr.c
blob: d6fe1da36921fd95335f5e2dead8bc2922f38d00 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include <wchar.h>

wchar_t *wcsrchr(const wchar_t *s, wchar_t c)
{
	const wchar_t *p;
	for (p=s+wcslen(s); p>=s && *p!=c; p--);
	return p>=s ? (wchar_t *)p : 0;
}


#ifdef TEST
int
main(void) {
	return 0;
}
#endif