I need a function like memchr() but it should be able to locate a substring(string), not an only single char. And it should return the first occurrence found in string.
For example
p1 = afunclikememchr(str1,"here the function that can locate this substring",200);
To the mods: I added the C++ tag because this is also relevant to C++
In a nutshell: I want a function that would be called memstr()
, conventionally.
In addition, I must use C standard libraries, not C++, and the function should not stop when it founds a '\0'
byte.