mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
drivers/xbee: Fix reference to device from netif in send function
This commit is contained in:
parent
309995513e
commit
40794cf5f1
@ -116,12 +116,12 @@ static int xbee_adpt_send(gnrc_netif_t *netif, gnrc_pktsnip_t *pkt)
|
||||
hdr = (gnrc_netif_hdr_t *)pkt->data;
|
||||
if (hdr->flags & BCAST) {
|
||||
uint16_t addr = 0xffff;
|
||||
res = xbee_build_hdr((xbee_t *)netif, xhdr, size, &addr, 2);
|
||||
res = xbee_build_hdr((xbee_t *)netif->dev, xhdr, size, &addr, 2);
|
||||
DEBUG("[xbee-gnrc] send: preparing to send broadcast\n");
|
||||
}
|
||||
else {
|
||||
uint8_t *addr = gnrc_netif_hdr_get_dst_addr(hdr);
|
||||
res = xbee_build_hdr((xbee_t *)netif, xhdr, size, addr,
|
||||
res = xbee_build_hdr((xbee_t *)netif->dev, xhdr, size, addr,
|
||||
hdr->dst_l2addr_len);
|
||||
if (res < 0) {
|
||||
if (res == -EOVERFLOW) {
|
||||
|
Loading…
Reference in New Issue
Block a user