From b81faa983634e9dcb409157b95e79a7c28a66c10 Mon Sep 17 00:00:00 2001
In-Reply-To: <6ee28a662c511063cd5edc32b6a613aa84cff3b9.1493385541.git.phrdina@redhat.com>
References: <6ee28a662c511063cd5edc32b6a613aa84cff3b9.1493385541.git.phrdina@redhat.com>
From: Pavel Hrdina <phrdina@redhat.com>
Date: Thu, 27 Apr 2017 15:28:41 -0400
Subject: sshtunnels: Detect listen type=none for VNC (bz 1445714)
From: Cole Robinson <crobinso@redhat.com>
https://bugzilla.redhat.com/show_bug.cgi?id=1445714
(cherry picked from commit cd0e3a897c2fa0f7efb0149dcbb6848844fb724b)
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1445714
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
---
virtManager/sshtunnels.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/virtManager/sshtunnels.py b/virtManager/sshtunnels.py
index 62eae42e..507eb559 100644
--- a/virtManager/sshtunnels.py
+++ b/virtManager/sshtunnels.py
@@ -38,6 +38,7 @@ class ConnectionInfo(object):
self.gsocket = gdev.socket
self.gaddr = gdev.listen or "127.0.0.1"
self.gtlsport = gdev.tlsPort or None
+ self.glistentype = gdev.get_first_listen_type()
self.transport = conn.get_uri_transport()
self.connuser = conn.get_uri_username()
@@ -60,6 +61,8 @@ class ConnectionInfo(object):
return False
def _is_listen_none(self):
+ if self.glistentype == "none":
+ return True
return not (self.gsocket or self.gport or self.gtlsport)
def need_tunnel(self):
--
2.12.2