I'm sure the original intention was to switch the port if the target
port is available on the currently active profile.
---
 src/modules/module-switch-on-port-available.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/module-switch-on-port-available.c 
b/src/modules/module-switch-on-port-available.c
index e5e1e9d..9bfb43f 100644
--- a/src/modules/module-switch-on-port-available.c
+++ b/src/modules/module-switch-on-port-available.c
@@ -193,7 +193,7 @@ static bool switch_to_port(pa_device_port *port) {
     pa_log_debug("Trying to switch to port %s", port->name);
     if (!pp.is_preferred_profile_active) {
         if (try_to_switch_profile(port) < 0) {
-            if (pp.is_possible_profile_active)
+            if (!pp.is_possible_profile_active)
                 return false;
         }
         else
-- 
2.7.0

_______________________________________________
pulseaudio-discuss mailing list
pulseaudio-discuss@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss

Reply via email to