TSCH: handle error cases returning -1 properly
- tsch_send_eb_process() in tsch-slot-operation.c - tsch_rx_slot() in tsch.c
This commit is contained in:
parent
0b81c0de18
commit
35a1701236
2 changed files with 15 additions and 13 deletions
|
@ -749,7 +749,7 @@ PROCESS_THREAD(tsch_send_eb_process, ev, data)
|
|||
#endif /* LLSEC802154_ENABLED */
|
||||
eb_len = tsch_packet_create_eb(packetbuf_dataptr(), PACKETBUF_SIZE,
|
||||
&hdr_len, &tsch_sync_ie_offset);
|
||||
if(eb_len != 0) {
|
||||
if(eb_len > 0) {
|
||||
struct tsch_packet *p;
|
||||
packetbuf_set_datalen(eb_len);
|
||||
/* Enqueue EB packet */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue