mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-31 22:25:33 -04:00
card: Remove some unnecessary checks.
This commit is contained in:
parent
78df02dba6
commit
dd6c8ae38f
1 changed files with 6 additions and 10 deletions
|
|
@ -181,20 +181,16 @@ pa_card *pa_card_new(pa_core *core, pa_card_new_data *data) {
|
|||
|
||||
/* As a minor optimization we just steal the list instead of
|
||||
* copying it here */
|
||||
c->profiles = data->profiles;
|
||||
pa_assert_se(c->profiles = data->profiles);
|
||||
data->profiles = NULL;
|
||||
c->ports = data->ports;
|
||||
pa_assert_se(c->ports = data->ports);
|
||||
data->ports = NULL;
|
||||
|
||||
if (c->profiles) {
|
||||
PA_HASHMAP_FOREACH(profile, c->profiles, state)
|
||||
profile->card = c;
|
||||
}
|
||||
PA_HASHMAP_FOREACH(profile, c->profiles, state)
|
||||
profile->card = c;
|
||||
|
||||
if (c->ports) {
|
||||
PA_HASHMAP_FOREACH(port, c->ports, state)
|
||||
port->card = c;
|
||||
}
|
||||
PA_HASHMAP_FOREACH(port, c->ports, state)
|
||||
port->card = c;
|
||||
|
||||
c->active_profile = NULL;
|
||||
c->save_profile = FALSE;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue