From: Denis Kenzior Date: Fri, 18 Dec 2009 03:25:15 +0000 (-0600) Subject: Style: Flip the if statement X-Git-Tag: 0.15~9 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7ffd9cb8e890d69a606506adb86e0828ad09d253;p=platform%2Fupstream%2Fofono.git Style: Flip the if statement The if case should have the multiple expressions --- diff --git a/src/cbs.c b/src/cbs.c index 6802dcb..72a380d 100644 --- a/src/cbs.c +++ b/src/cbs.c @@ -437,13 +437,13 @@ static DBusMessage *cbs_set_powered(struct ofono_cbs *cbs, gboolean value, if (msg) cbs->pending = dbus_message_ref(msg); - if (!value) - cbs->driver->clear_topics(cbs, cbs_set_powered_cb, cbs); - else { + if (value) { topic_str = cbs_topics_to_str(cbs, cbs->topics); cbs->driver->set_topics(cbs, topic_str, cbs_set_powered_cb, cbs); g_free(topic_str); + } else { + cbs->driver->clear_topics(cbs, cbs_set_powered_cb, cbs); } return NULL;