chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
5a0cbe386e320672159e6d3458eaae895467ae44
[elogind.git]
/
klibc
/
klibc
/
strrchr.c
1
/*
2
* strrchr.c
3
*/
4
5
#include <string.h>
6
#include <klibc/compiler.h>
7
8
char *strrchr(const char *s, int c)
9
{
10
const char *found = NULL;
11
12
while ( *s ) {
13
if ( *s == (char) c )
14
found = s;
15
s++;
16
}
17
18
return (char *)found;
19
}
20
21
__ALIAS(char *, rindex, (const char *, int), strrchr)