I'm new to C++, and I have a function,
char* parse( char* buf, char* find_this ) which finds an instance of
find_this inside of
buf . Once it finds that, it looks ahead in the
buf text, (which is actually JSON formatted) finds the value in the text, and it returns a pointer to a char array (created with
new ) of that value.
When called once, it works fine. But when I call it multiple times, I get strange errors, usually a bus error but sometimes more lengthy ones. I think it's the way I'm using my types...anyone have any suggestions? Thanks