[node-patches] Change in ovirt-node[master]: Fixing correct terminal detection

tlitovsk at redhat.com tlitovsk at redhat.com
Wed Nov 19 16:57:32 UTC 2014


Anatoly Litovsky has posted comments on this change.

Change subject: Fixing correct terminal detection
......................................................................


Patch Set 1:

(1 comment)

inline 
and i still need to fix staff (jenkins is right )

http://gerrit.ovirt.org/#/c/35348/1/src/ovirt/node/utils/console.py
File src/ovirt/node/utils/console.py:

Line 32:     """Is true if the terminal is a real one
Line 33:     Like the linux terminal console
Line 34:     """
Line 35:     ttyname = os.ttyname(sys.stdin.fileno())
Line 36:     return re.search(ttyname, "/dev/tty(([0-9][10-99])|[0-9]|)") != None \
> That expression can be much simpler:
but we must catch those too
/dev/tty
dev/tty/10,11,.....99
Line 37:            or ttyname == "/dev/console"
Line 38: 
Line 39: 
Line 40: def is_pty():


-- 
To view, visit http://gerrit.ovirt.org/35348
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I010c2bf79bfe98b3b5ebc2f54246690c1bcfbffc
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Anatoly Litovsky <tlitovsk at redhat.com>
Gerrit-Reviewer: Anatoly Litovsky <tlitovsk at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fabiand at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes



More information about the node-patches mailing list