How do I modify a pointer that has been passed into a function in C?
You need to pass in a pointer to a pointer if you want to do this. void barPush(BarList ** list,Bar * bar) { if (list == NULL) return; // need to pass in the pointer to your pointer to your list. // if there is no move to add, then we are done if (bar … Read more