Returning path info from BFS