MCPcopy Create free account
hub / github.com/cppla/ServerStatus / str_find_nocase

Function str_find_nocase

server/src/system.c:1704–1721  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1702}
1703
1704const char *str_find_nocase(const char *haystack, const char *needle)
1705{
1706 while(*haystack) /* native implementation */
1707 {
1708 const char *a = haystack;
1709 const char *b = needle;
1710 while(*a && *b && tolower(*a) == tolower(*b))
1711 {
1712 a++;
1713 b++;
1714 }
1715 if(!(*b))
1716 return haystack;
1717 haystack++;
1718 }
1719
1720 return 0;
1721}
1722
1723
1724const char *str_find(const char *haystack, const char *needle)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected