From 6973e91ade51fa5abf41ca4189b5f4eeb2b4a401 Mon Sep 17 00:00:00 2001 From: Orne Brocaar Date: Tue, 8 Nov 2022 15:40:37 +0000 Subject: [PATCH] Remove unsetting of device_queue_item. In case the queue-item does fit the first RX window, but not the second one, it will be set to None. If this happens, then the save_downlink_frame step will not add the queue-item ID to the DownlinkFrame (internal). Then on txack, ChirpStack is unable to dequeue the payload causing the payload to stay in the queue. --- chirpstack/src/downlink/data.rs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/chirpstack/src/downlink/data.rs b/chirpstack/src/downlink/data.rs index 13db2555..fe061cd4 100644 --- a/chirpstack/src/downlink/data.rs +++ b/chirpstack/src/downlink/data.rs @@ -495,9 +495,6 @@ impl Data { // Network-server FCnt. mac_pl.fhdr.f_cnt = self.device_session.n_f_cnt_down; - - // Unset queue-item. - self.device_queue_item = None; } else { // In this case mac-commands are sent using the FOpts field. In case there // is a device-queue item, we will validate if it still fits within the @@ -531,7 +528,6 @@ impl Data { } else { f_pending = true; mac_pl.fhdr.f_ctrl.f_pending = true; - self.device_queue_item = None; } } }