Moved the link layer destination check to sicslowmac
This commit is contained in:
parent
0c4dc6fc6b
commit
0ad51b8dcc
2 changed files with 9 additions and 13 deletions
|
@ -28,7 +28,7 @@
|
|||
*
|
||||
* This file is part of the Contiki operating system.
|
||||
*
|
||||
* $Id: sicslowmac.c,v 1.3 2009/06/22 11:14:11 nifi Exp $
|
||||
* $Id: sicslowmac.c,v 1.4 2009/09/18 16:37:17 nifi Exp $
|
||||
*/
|
||||
|
||||
|
||||
|
@ -190,10 +190,15 @@ read_packet(void)
|
|||
/* Not broadcast or for our PAN */
|
||||
PRINTF("6MAC: for another pan %u\n", frame.dest_pid);
|
||||
return 0;
|
||||
|
||||
}
|
||||
if(!is_broadcast_addr(frame.fcf.dest_addr_mode, frame.dest_addr.u8)) {
|
||||
packetbuf_set_addr(PACKETBUF_ADDR_RECEIVER, &frame.dest_addr);
|
||||
if(!rimeaddr_cmp(packetbuf_addr(PACKETBUF_ADDR_RECEIVER),
|
||||
&rimeaddr_node_addr)) {
|
||||
/* Not for this node */
|
||||
PRINTF("6MAC: not for us\n");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
packetbuf_set_addr(PACKETBUF_ADDR_SENDER, &frame.src_addr);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue