mirror of
https://gitlab.com/mobian1/eg25-manager.git
synced 2025-08-29 07:12:08 +02:00
at: log expected result before setting it to NULL
Otherwise the log contains NULL instead of the expected value, making it hard to debug
This commit is contained in:
4
src/at.c
4
src/at.c
@@ -151,9 +151,9 @@ void at_process_result(struct EG25Manager *manager,
|
||||
if (at_cmd->expected && !strstr(response, at_cmd->expected)) {
|
||||
g_free(at_cmd->value);
|
||||
at_cmd->value = at_cmd->expected;
|
||||
at_cmd->expected = NULL;
|
||||
g_message("Got a different result than expected, changing value...");
|
||||
g_message("\t%s\n\t%s", at_cmd->expected, response);
|
||||
g_message("Expected: [%s]\nResponse: [%s]", at_cmd->expected, response);
|
||||
at_cmd->expected = NULL;
|
||||
at_send_command(manager);
|
||||
} else {
|
||||
at_next_command(manager);
|
||||
|
Reference in New Issue
Block a user