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

Function str_find

server/src/system.c:1724–1741  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1722
1723
1724const char *str_find(const char *haystack, const char *needle)
1725{
1726 while(*haystack) /* native implementation */
1727 {
1728 const char *a = haystack;
1729 const char *b = needle;
1730 while(*a && *b && *a == *b)
1731 {
1732 a++;
1733 b++;
1734 }
1735 if(!(*b))
1736 return haystack;
1737 haystack++;
1738 }
1739
1740 return 0;
1741}
1742
1743void str_hex(char *dst, int dst_size, const void *data, int data_size)
1744{

Callers 1

UpdateMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected