Fixed compiler warning in graph.cpp