Added and updated debugging printouts and reformatted code to make it a little easier to read.

This commit is contained in:
Adam Dunkels 2013-08-11 23:42:51 +02:00 committed by Simon Duquennoy
parent 248301a041
commit 82e8eb420d
4 changed files with 39 additions and 5 deletions

View file

@ -183,6 +183,7 @@ rpl_link_neighbor_callback(const rimeaddr_t *addr, int status, int numtx)
parent = rpl_find_parent_any_dag(instance, &ipaddr);
if(parent != NULL) {
/* Trigger DAG rank recalculation. */
PRINTF("RPL: rpl_link_neighbor_callback triggering update\n");
parent->updated = 1;
if(instance->of->neighbor_link_callback != NULL) {
instance->of->neighbor_link_callback(parent, status, numtx);
@ -208,6 +209,7 @@ rpl_ipv6_neighbor_callback(uip_ds6_nbr_t *nbr)
if(p != NULL) {
p->rank = INFINITE_RANK;
/* Trigger DAG rank recalculation. */
PRINTF("RPL: rpl_ipv6_neighbor_callback infinite rank\n");
p->updated = 1;
}
}