summaryrefslogtreecommitdiffstats
path: root/src/tlv_types.c
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-03-18 17:56:29 +0100
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-03-18 17:56:29 +0100
commit3af74a4b534186c966728785a05b0f72dc2b6048 (patch)
treee1f4796683d7d03cfc9d8a2e77401e15de694708 /src/tlv_types.c
parent0587bef25eb23f58aad1cd0b39d6bcb2dd074578 (diff)
downloadbabel-3af74a4b534186c966728785a05b0f72dc2b6048.tar
babel-3af74a4b534186c966728785a05b0f72dc2b6048.zip
Add GMRF debug calls
Diffstat (limited to 'src/tlv_types.c')
-rw-r--r--src/tlv_types.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/tlv_types.c b/src/tlv_types.c
index 850acfb..279aaab 100644
--- a/src/tlv_types.c
+++ b/src/tlv_types.c
@@ -111,6 +111,7 @@ static void handle_tlv_hello(gmrf_context_t *ctx, const gp_babel_tlv_hello_t *tl
gp_babel_neigh_reset(ctx, arg->iface, neigh);
gmrf_logf(ctx->gmrf, LOG_DEBUG, "accepted hello, log %04x, rxcost is %u, cost is %u now.", neigh->hello_log, gp_babel_neigh_get_rxcost(ctx, neigh), gp_babel_neigh_get_cost(ctx, neigh));
+ gmrf_debug_neigh(ctx->gmrf, arg->iface->gmrf_iface, &neigh->addr, gp_babel_neigh_get_rxcost(ctx, neigh), gp_babel_neigh_get_txcost(ctx, neigh));
}
static void handle_tlv_ihu(gmrf_context_t *ctx, const gp_babel_tlv_ihu_t *tlv, size_t len, handle_tlv_arg_t *arg) {
@@ -139,6 +140,7 @@ static void handle_tlv_ihu(gmrf_context_t *ctx, const gp_babel_tlv_ihu_t *tlv, s
neigh->txcost = ntohs(tlv->rxcost);
gmrf_logf(ctx->gmrf, LOG_DEBUG, "accepted IHU, txcost is %u, cost is %u now.", gp_babel_neigh_get_txcost(ctx, neigh), gp_babel_neigh_get_cost(ctx, neigh));
+ gmrf_debug_neigh(ctx->gmrf, arg->iface->gmrf_iface, &neigh->addr, gp_babel_neigh_get_rxcost(ctx, neigh), gp_babel_neigh_get_txcost(ctx, neigh));
}
static void handle_tlv_node_id(gmrf_context_t *ctx, const gp_babel_tlv_node_id_t *tlv, size_t len, handle_tlv_arg_t *arg) {