Scan a string for the last occurrence of a character */
| 132 | |
| 133 | /* Scan a string for the last occurrence of a character */ |
| 134 | char *strrchr (const char *str, int c) |
| 135 | { |
| 136 | char * save; |
| 137 | |
| 138 | for (save = NULL; ; ++str) { |
| 139 | if (*str == c) { |
| 140 | save = (char *)str; |
| 141 | } |
| 142 | if (*str == 0) { |
| 143 | return (save); |
| 144 | } |
| 145 | } |
| 146 | } |
| 147 | |
| 148 | /* Read formatted data from a string */ |
| 149 | int sscanf (const char *buffer, const char *format, ...) |
no outgoing calls
no test coverage detected