Depth First Search in C