New answers tagged


The various branches are mutually exclusive. Only one of them will execute the way you've written it. But you want to free both the parents and the person. And why check for NULL here? else if(p->parents[0] != NULL) { free_family(p->parents[0]); } The parent will just be checked for NULL again once it is passed to free_family as a person.

Top 50 recent answers are included