From: Tanu Kaskinen Date: Sat, 15 Aug 2009 02:51:55 +0000 (+0300) Subject: dbusiface-card: Split some overly long lines. X-Git-Tag: v0.98-dev~354^2~45 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8b5550dba32857918fd8e70b93be9094c11cf0c8;p=platform%2Fupstream%2Fpulseaudio.git dbusiface-card: Split some overly long lines. --- diff --git a/src/modules/dbus/iface-card-profile.c b/src/modules/dbus/iface-card-profile.c index 2b85a5f..4a1696c 100644 --- a/src/modules/dbus/iface-card-profile.c +++ b/src/modules/dbus/iface-card-profile.c @@ -182,7 +182,11 @@ static void handle_get_all(DBusConnection *conn, DBusMessage *msg, void *userdat dbus_message_unref(reply); } -pa_dbusiface_card_profile *pa_dbusiface_card_profile_new(pa_dbusiface_card *card, pa_core *core, pa_card_profile *profile, uint32_t idx) { +pa_dbusiface_card_profile *pa_dbusiface_card_profile_new( + pa_dbusiface_card *card, + pa_core *core, + pa_card_profile *profile, + uint32_t idx) { pa_dbusiface_card_profile *p = NULL; pa_assert(card); diff --git a/src/modules/dbus/iface-card-profile.h b/src/modules/dbus/iface-card-profile.h index 9edcde7..a09767f 100644 --- a/src/modules/dbus/iface-card-profile.h +++ b/src/modules/dbus/iface-card-profile.h @@ -37,7 +37,11 @@ typedef struct pa_dbusiface_card_profile pa_dbusiface_card_profile; -pa_dbusiface_card_profile *pa_dbusiface_card_profile_new(pa_dbusiface_card *card, pa_core *core, pa_card_profile *profile, uint32_t idx); +pa_dbusiface_card_profile *pa_dbusiface_card_profile_new( + pa_dbusiface_card *card, + pa_core *core, + pa_card_profile *profile, + uint32_t idx); void pa_dbusiface_card_profile_free(pa_dbusiface_card_profile *p); const char *pa_dbusiface_card_profile_get_path(pa_dbusiface_card_profile *p); diff --git a/src/modules/dbus/iface-card.c b/src/modules/dbus/iface-card.c index 64ec12a..40031d2 100644 --- a/src/modules/dbus/iface-card.c +++ b/src/modules/dbus/iface-card.c @@ -312,7 +312,10 @@ static void handle_get_active_profile(DBusConnection *conn, DBusMessage *msg, vo pa_assert(c); if (!c->active_profile) { - pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, "The card %s has no profiles, and therefore there's no active profile either.", c->card->name); + pa_assert(pa_hashmap_isempty(c->profiles)); + + pa_dbus_send_error(conn, msg, PA_DBUS_ERROR_NO_SUCH_PROPERTY, + "The card %s has no profiles, and therefore there's no active profile either.", c->card->name); return; } @@ -470,7 +473,9 @@ static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint3 c->active_profile = c->card->active_profile; object_path = pa_dbusiface_card_profile_get_path(pa_hashmap_get(c->profiles, c->active_profile->name)); - pa_assert_se(signal = dbus_message_new_signal(c->path, PA_DBUSIFACE_CARD_INTERFACE, signals[SIGNAL_ACTIVE_PROFILE_UPDATED].name)); + pa_assert_se(signal = dbus_message_new_signal(c->path, + PA_DBUSIFACE_CARD_INTERFACE, + signals[SIGNAL_ACTIVE_PROFILE_UPDATED].name)); pa_assert_se(dbus_message_append_args(signal, DBUS_TYPE_OBJECT_PATH, &object_path, DBUS_TYPE_INVALID)); pa_dbus_protocol_send_signal(c->dbus_protocol, signal); @@ -483,7 +488,9 @@ static void subscription_cb(pa_core *core, pa_subscription_event_type_t t, uint3 pa_proplist_update(c->proplist, PA_UPDATE_SET, c->card->proplist); - pa_assert_se(signal = dbus_message_new_signal(c->path, PA_DBUSIFACE_CARD_INTERFACE, signals[SIGNAL_PROPERTY_LIST_UPDATED].name)); + pa_assert_se(signal = dbus_message_new_signal(c->path, + PA_DBUSIFACE_CARD_INTERFACE, + signals[SIGNAL_PROPERTY_LIST_UPDATED].name)); dbus_message_iter_init_append(signal, &msg_iter); pa_dbus_append_proplist(&msg_iter, c->proplist);