- /* Check if we have the headers we need */
- if(routing_mode != RMODE_ROUTER && !(type & PKT_MAC)) {
- logger(DEBUG_TRAFFIC, LOG_ERR, "Received packet from %s (%s) without MAC header (maybe Mode is not set correctly)", from->name, from->hostname);
- return false;
- } else if(routing_mode == RMODE_ROUTER && (type & PKT_MAC)) {
- logger(DEBUG_TRAFFIC, LOG_WARNING, "Received packet from %s (%s) with MAC header (maybe Mode is not set correctly)", from->name, from->hostname);
- }
-
- int offset = (type & PKT_MAC) ? 0 : 14;