* [PATCH] It is better to use decode_at_error.
@ 2011-07-07 16:39 Bertrand Aygon
2011-07-07 6:15 ` Denis Kenzior
0 siblings, 1 reply; 2+ messages in thread
From: Bertrand Aygon @ 2011-07-07 16:39 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 1281 bytes --]
---
plugins/zte.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/plugins/zte.c b/plugins/zte.c
index 822098d..6a4b374 100644
--- a/plugins/zte.c
+++ b/plugins/zte.c
@@ -233,11 +233,10 @@ static void set_online_cb(gboolean ok, GAtResult *result, gpointer user_data)
{
struct cb_data *cbd = user_data;
ofono_modem_online_cb_t cb = cbd->cb;
+ struct ofono_error error;
- if (ok)
- CALLBACK_WITH_SUCCESS(cb, cbd->data);
- else
- CALLBACK_WITH_FAILURE(cb, cbd->data);
+ decode_at_error(&error, g_at_result_final_response(result));
+ cb(&error, cbd->data);
}
static void zte_set_online(struct ofono_modem *modem, ofono_bool_t online,
--
1.7.4.1
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris,
92196 Meudon Cedex, France
Registration Number: 302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros
This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-07-07 16:39 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-07 16:39 [PATCH] It is better to use decode_at_error Bertrand Aygon
2011-07-07 6:15 ` Denis Kenzior
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.