Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion connectivity/lorawan/source/LoRaWANStack.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -756,7 +756,10 @@ void LoRaWANStack::process_reception_timeout(bool is_timeout)
_loramac.on_radio_rx_timeout(is_timeout);

if (slot == RX_SLOT_WIN_2 && !_loramac.nwk_joined()) {
state_controller(DEVICE_STATE_JOINING);
const int ret = _queue->call_in(
500, this, &LoRaWANStack::state_controller, DEVICE_STATE_JOINING);
MBED_ASSERT(ret != 0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lot of errors in this stack are reported just via tr_error. Should this be the same?
or just use error() instead of assert in this case

Copy link
Contributor Author

@zul00 zul00 Feb 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the other locations, failure from EventQueue::call which indicates failure in allocating the event, would be handled by assertion. for example:

const int ret = _queue->call(this, &LoRaWANStack::process_transmission);
MBED_ASSERT(ret != 0);
(void)ret;

So I am following the same pattern.

(void)ret;
return;
}

Expand Down