From 7972a780945299b992643838e61426323b161cfe Mon Sep 17 00:00:00 2001 From: Saverio Proto Date: Thu, 17 Apr 2014 19:53:41 +0200 Subject: [PATCH] Debug messages in route function --- src/route.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/route.c b/src/route.c index 317d120f..cffb7d25 100644 --- a/src/route.c +++ b/src/route.c @@ -66,6 +66,7 @@ void route(node_t *source,vpn_packet_t *packet) { node_t* via = NULL; tincpackethdr* hdr = (tincpackethdr*)packet->data; owner = lookup_node(hdr->destination); + logger(DEBUG_TRAFFIC, LOG_WARNING, "Routing packet from: %s . To: %s \n",hdr->source,hdr->destination); //Check Lenght if(!checklength(source, packet, (sizeof(tincpackethdr)))) @@ -74,6 +75,7 @@ void route(node_t *source,vpn_packet_t *packet) { if (owner == NULL) { //Lookup failed logger(DEBUG_TRAFFIC, LOG_WARNING, "Cant lookup the owner of a packet in the route() function. This should never happen \n"); + logger(DEBUG_TRAFFIC, LOG_WARNING, "Destination was: %s \n",hdr->destination); return; } -- 2.39.5