| 1754 | |
| 1755 | |
| 1756 | size_t strccnt(const char *s, int c) |
| 1757 | { |
| 1758 | const unsigned char *us = (const unsigned char *) s; |
| 1759 | const unsigned char uc = c; |
| 1760 | size_t n = 0; |
| 1761 | if (!uc) return 1; |
| 1762 | while (*us) if (*us++ == uc) n++; |
| 1763 | return n; |
| 1764 | } |
| 1765 | |
| 1766 | |
| 1767 | void strkeepOnly(char *s, const char *c) { |
no outgoing calls
no test coverage detected