diff options
author | Aleksander Morgado <aleksander@lanedo.com> | 2012-09-28 20:35:41 +0200 |
---|---|---|
committer | Aleksander Morgado <aleksander@lanedo.com> | 2012-09-28 20:35:41 +0200 |
commit | b622424d2fdcd1f455c3ecbc86a7624a39050f2d (patch) | |
tree | 5fc6441456f95943d460a3dfa2b6e55c4797730e | |
parent | 00a8ed3af44835ccb83c05c2ecfec2a119320420 (diff) |
broadband-modem: handle unknown errors in AT sequences
When none of the commands in the AT sequence succeeds no error is set.
-rw-r--r-- | src/mm-broadband-modem.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mm-broadband-modem.c b/src/mm-broadband-modem.c index 80cc4225..76eec7c9 100644 --- a/src/mm-broadband-modem.c +++ b/src/mm-broadband-modem.c @@ -3179,7 +3179,10 @@ unsolicited_registration_events_sequence_ready (MMBroadbandModem *self, /* We just run the sequence in the primary port */ command = mm_base_modem_at_sequence_finish (MM_BASE_MODEM (self), res, NULL, &error); if (!command) { - g_assert (error != NULL); + if (!error) + error = g_error_new (MM_CORE_ERROR, + MM_CORE_ERROR_FAILED, + "AT sequence failed"); mm_dbg ("%s unsolicited registration events in primary port failed: '%s'", ctx->enable ? "Enabling" : "Disabling", error->message); |