From: Samuel Ortiz Date: Thu, 1 Dec 2011 11:21:41 +0000 (+0100) Subject: technology: Check if pending message is NULL before sending it back X-Git-Tag: 2.0_alpha~890 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1f6c5b248cd0c15d6cb34143ff6f7c8b373fe7d9;p=framework%2Fconnectivity%2Fconnman.git technology: Check if pending message is NULL before sending it back The message would be NULL when setting offline mode on and off. Fixes BMC#24314 --- diff --git a/src/technology.c b/src/technology.c index cfa7972..fb28ca5 100644 --- a/src/technology.c +++ b/src/technology.c @@ -881,7 +881,8 @@ int __connman_technology_enable(enum connman_service_type type, DBusMessage *msg done: if (ret == 0) { - g_dbus_send_reply(connection, msg, DBUS_TYPE_INVALID); + if (msg != NULL) + g_dbus_send_reply(connection, msg, DBUS_TYPE_INVALID); return ret; } @@ -967,7 +968,8 @@ int __connman_technology_disable(enum connman_service_type type, DBusMessage *ms done: if (ret == 0) { - g_dbus_send_reply(connection, msg, DBUS_TYPE_INVALID); + if (msg != NULL) + g_dbus_send_reply(connection, msg, DBUS_TYPE_INVALID); return ret; }