added code to print out a routingTable before calling getNextHop in routepacket