sshtunnels: Detect listen type=none for VNC (bz 1445714)

https://bugzilla.redhat.com/show_bug.cgi?id=1445714
This commit is contained in:
Cole Robinson 2017-04-27 15:28:41 -04:00
parent c0a3234633
commit cd0e3a897c
1 changed files with 3 additions and 0 deletions

View File

@ -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):