File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,12 +30,12 @@ def unix_getpass(prompt='Password: '):
3030 old = termios .tcgetattr (fd ) # a copy to save
3131 new = old [:]
3232
33- new [3 ] = new [3 ] & ~ TERMIOS .ECHO # 3 == 'lflags'
33+ new [3 ] = new [3 ] & ~ termios .ECHO # 3 == 'lflags'
3434 try :
35- termios .tcsetattr (fd , TERMIOS .TCSADRAIN , new )
35+ termios .tcsetattr (fd , termios .TCSADRAIN , new )
3636 passwd = _raw_input (prompt )
3737 finally :
38- termios .tcsetattr (fd , TERMIOS .TCSADRAIN , old )
38+ termios .tcsetattr (fd , termios .TCSADRAIN , old )
3939
4040 sys .stdout .write ('\n ' )
4141 return passwd
@@ -103,7 +103,7 @@ def getuser():
103103
104104# Bind the name getpass to the appropriate function
105105try :
106- import termios , TERMIOS
106+ import termios
107107except ImportError :
108108 try :
109109 import msvcrt
Original file line number Diff line number Diff line change 22
33# Author: Steen Lumholt.
44
5- from TERMIOS import *
65from termios import *
76
87# Indexes for termios list.
You can’t perform that action at this time.
0 commit comments