modem: hl7800: fix +CFUN handler
Fix the +CFUN command handler to find the end of the message properly. Signed-off-by: Ryan Erickson <ryan.erickson@lairdconnect.com>
This commit is contained in:
parent
9a088f9778
commit
48cca618fb
1 changed files with 2 additions and 2 deletions
|
@ -3336,15 +3336,15 @@ done:
|
||||||
|
|
||||||
static bool on_cmd_modem_functionality(struct net_buf **buf, uint16_t len)
|
static bool on_cmd_modem_functionality(struct net_buf **buf, uint16_t len)
|
||||||
{
|
{
|
||||||
struct net_buf *frag = NULL;
|
struct net_buf *frag;
|
||||||
size_t out_len;
|
size_t out_len;
|
||||||
char rsp[MDM_HL7800_MODEM_FUNCTIONALITY_SIZE];
|
char rsp[MDM_HL7800_MODEM_FUNCTIONALITY_SIZE];
|
||||||
|
|
||||||
wait_for_modem_data_and_newline(buf, net_buf_frags_len(*buf),
|
wait_for_modem_data_and_newline(buf, net_buf_frags_len(*buf),
|
||||||
MDM_HL7800_MODEM_FUNCTIONALITY_SIZE);
|
MDM_HL7800_MODEM_FUNCTIONALITY_SIZE);
|
||||||
|
|
||||||
len = net_buf_findcrlf(*buf, &frag);
|
|
||||||
frag = NULL;
|
frag = NULL;
|
||||||
|
len = net_buf_findcrlf(*buf, &frag);
|
||||||
if (!frag) {
|
if (!frag) {
|
||||||
LOG_ERR("Unable to find end of response");
|
LOG_ERR("Unable to find end of response");
|
||||||
goto done;
|
goto done;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue