pulse-server: small cleanup

This commit is contained in:
Wim Taymans 2020-10-27 08:59:53 +01:00
parent 51328af0e1
commit 496f3842be

View file

@ -2616,16 +2616,19 @@ static int fill_card_info(struct client *client, struct message *m,
n_profiles = n_ports = 0; n_profiles = n_ports = 0;
spa_list_for_each(p, &o->param_list, link) { spa_list_for_each(p, &o->param_list, link) {
if (p->id == SPA_PARAM_Profile) { switch (p->id) {
if (spa_pod_parse_object(p->param, case SPA_PARAM_Profile:
spa_pod_parse_object(p->param,
SPA_TYPE_OBJECT_ParamProfile, NULL, SPA_TYPE_OBJECT_ParamProfile, NULL,
SPA_PARAM_PROFILE_index, SPA_POD_Int(&active_profile)) < 0) SPA_PARAM_PROFILE_index, SPA_POD_Int(&active_profile));
continue; break;
} case SPA_PARAM_EnumProfile:
else if (p->id == SPA_PARAM_EnumProfile)
n_profiles++; n_profiles++;
else if (p->id == SPA_PARAM_EnumRoute) break;
case SPA_PARAM_EnumRoute:
n_ports++; n_ports++;
break;
}
} }
message_put(m, message_put(m,