source: buchla-68k/libsm/rindex.c@ 7258c6a

Last change on this file since 7258c6a was 7258c6a, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Use standard integer types.

  • Property mode set to 100644
File size: 421 bytes
Line 
1/*
2 ============================================================================
3 rindex.c -- BSD style rindex function
4 Version 2 -- 1987-06-12 -- D.N. Lynx Crowe
5 ============================================================================
6*/
7
8int8_t *rindex(int8_t *str, int8_t c)
9{
10 register int8_t *cp;
11
12 for (cp = str ;*cp++ ; )
13 ;
14
15 while (cp > str)
16 if (*--cp == c)
17 return(cp);
18
19 return((int8_t *)0);
20}
21
Note: See TracBrowser for help on using the repository browser.