add a nullCheck when getting the adjacent routers.

possibly a check in the main loop missed also, but havn't seen an NPE
error from that point.

fixes #533