router.c in progress