From 22f1aecd7a491e76d702dd55e81ecfbc63525362 Mon Sep 17 00:00:00 2001 From: David Cermak Date: Tue, 26 Sep 2023 15:14:53 +0200 Subject: [PATCH] fix(modem): Fix to allow MSC frame (SIM800 CMUX) after v1.0.2 --- components/esp_modem/src/esp_modem_cmux.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/esp_modem/src/esp_modem_cmux.cpp b/components/esp_modem/src/esp_modem_cmux.cpp index 1ce67a61f61..a04c1808db4 100644 --- a/components/esp_modem/src/esp_modem_cmux.cpp +++ b/components/esp_modem/src/esp_modem_cmux.cpp @@ -144,7 +144,7 @@ bool CMux::data_available(uint8_t *data, size_t len) return false; } } else if ((type & FT_UIH) == FT_UIH && dlci == 0) { // notify the internal DISC command - if (len > 0 && (data[0] & 0xE1) == 0xE1) { + if ((len > 0 && (data[0] & 0xE1) == 0xE1) || (data == nullptr)) { // Not a DISC, ignore (MSC frame) return true; }