1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

Merge pull request #8209 from bergzand/pr/netifeth_oddebug

gnrc_netif: Fix compile errors when debug is enabled
This commit is contained in:
Martine Lenders 2017-12-05 16:28:22 +01:00 committed by GitHub
commit 7745060ad9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 3 deletions

View File

@ -26,6 +26,10 @@
#define ENABLE_DEBUG (0)
#include "debug.h"
#if defined(MODULE_OD) && ENABLE_DEBUG
#include "od.h"
#endif
static int _send(gnrc_netif_t *netif, gnrc_pktsnip_t *pkt);
static gnrc_pktsnip_t *_recv(gnrc_netif_t *netif);

View File

@ -24,6 +24,10 @@
#define ENABLE_DEBUG (0)
#include "debug.h"
#if defined(MODULE_OD) && ENABLE_DEBUG
#include "od.h"
#endif
#ifdef MODULE_NETDEV_IEEE802154
static int _send(gnrc_netif_t *netif, gnrc_pktsnip_t *pkt);
static gnrc_pktsnip_t *_recv(gnrc_netif_t *netif);
@ -137,9 +141,9 @@ static gnrc_pktsnip_t *_recv(gnrc_netif_t *netif)
pkt->type = state->proto;
#if ENABLE_DEBUG
DEBUG("_recv_ieee802154: received packet from %s of length %u\n",
gnrc_netif_addr_to_str(src_str, sizeof(src_str),
gnrc_netif_hdr_get_src_addr(hdr),
hdr->src_l2addr_len),
gnrc_netif_addr_to_str(gnrc_netif_hdr_get_src_addr(hdr),
hdr->src_l2addr_len,
src_str),
nread);
#if defined(MODULE_OD)
od_hex_dump(pkt->data, nread, OD_WIDTH_DEFAULT);