I have a graph and one parameter to the graph is an equality function.
This is the code I've written:
bool equalityFunction(void *char1,void *char2)
{
if(strncmp((char *)char1,(char *)char2, 20) == 0)
return true;
return false;
}
The function is supposed to take in struct-pointers and to check if these pointers point to structs that have charpointers that point on identical strings.
May be hard to understand or low information but can anyone think of how I could possible write the equalityFunction? Thanks.