switch-on-port-available: fix inverted if condition

I'm sure the original intention was to switch the port if the target
port is available on the currently active profile.
This commit is contained in:
Tanu Kaskinen 2016-03-04 15:23:28 +02:00 committed by Arun Raghavan
parent fe4f96d56e
commit a99eb81db3

View file

@ -193,7 +193,7 @@ static bool switch_to_port(pa_device_port *port) {
pa_log_debug("Trying to switch to port %s", port->name); pa_log_debug("Trying to switch to port %s", port->name);
if (!pp.is_preferred_profile_active) { if (!pp.is_preferred_profile_active) {
if (try_to_switch_profile(port) < 0) { if (try_to_switch_profile(port) < 0) {
if (pp.is_possible_profile_active) if (!pp.is_possible_profile_active)
return false; return false;
} }
else else