shithub: riscv

Download patch

ref: a118f445d5ab2af18c51287755aaf0e601289521
parent: 6e0dada472e48291d4a17201f64116d8ec9e4aa0
author: cinap_lenrek <cinap_lenrek@localhost>
date: Tue May 3 07:41:36 EDT 2011

getpass

--- a/.hgignore
+++ b/.hgignore
@@ -1,6 +1,6 @@
 syntax: regexp
 \.[ao]?[12578vqki]?$
-\.(pyo|exe)$
+\.(pyo|pyc|exe)$
 ^\.dummy$
 ^(dev|fd|net|srv|env|root|mnt|n)/
 ^(386|68000|68020|alpha|amd64|arm|power|power64|sparc|sparc64)/(bin|lib)/
binary files a/sys/lib/python/BaseHTTPServer.pyc /dev/null differ
binary files a/sys/lib/python/ConfigParser.pyc /dev/null differ
binary files a/sys/lib/python/SocketServer.pyc /dev/null differ
binary files a/sys/lib/python/UserDict.pyc /dev/null differ
binary files a/sys/lib/python/__future__.pyc /dev/null differ
binary files a/sys/lib/python/base64.pyc /dev/null differ
binary files a/sys/lib/python/bisect.pyc /dev/null differ
binary files a/sys/lib/python/calendar.pyc /dev/null differ
binary files a/sys/lib/python/cgi.pyc /dev/null differ
binary files a/sys/lib/python/codecs.pyc /dev/null differ
binary files a/sys/lib/python/commands.pyc /dev/null differ
binary files a/sys/lib/python/copy.pyc /dev/null differ
binary files a/sys/lib/python/copy_reg.pyc /dev/null differ
binary files a/sys/lib/python/difflib.pyc /dev/null differ
binary files a/sys/lib/python/dis.pyc /dev/null differ
binary files a/sys/lib/python/distutils/__init__.pyc /dev/null differ
binary files a/sys/lib/python/distutils/archive_util.pyc /dev/null differ
binary files a/sys/lib/python/distutils/ccompiler.pyc /dev/null differ
binary files a/sys/lib/python/distutils/cmd.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/__init__.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/bdist.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/build.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/build_ext.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/build_py.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/build_scripts.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/clean.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/install.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/install_data.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/install_egg_info.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/install_lib.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/install_scripts.pyc /dev/null differ
binary files a/sys/lib/python/distutils/command/sdist.pyc /dev/null differ
binary files a/sys/lib/python/distutils/core.pyc /dev/null differ
binary files a/sys/lib/python/distutils/debug.pyc /dev/null differ
binary files a/sys/lib/python/distutils/dep_util.pyc /dev/null differ
binary files a/sys/lib/python/distutils/dir_util.pyc /dev/null differ
binary files a/sys/lib/python/distutils/dist.pyc /dev/null differ
binary files a/sys/lib/python/distutils/errors.pyc /dev/null differ
binary files a/sys/lib/python/distutils/extension.pyc /dev/null differ
binary files a/sys/lib/python/distutils/fancy_getopt.pyc /dev/null differ
binary files a/sys/lib/python/distutils/file_util.pyc /dev/null differ
binary files a/sys/lib/python/distutils/filelist.pyc /dev/null differ
binary files a/sys/lib/python/distutils/log.pyc /dev/null differ
binary files a/sys/lib/python/distutils/spawn.pyc /dev/null differ
binary files a/sys/lib/python/distutils/sysconfig.pyc /dev/null differ
binary files a/sys/lib/python/distutils/text_file.pyc /dev/null differ
binary files a/sys/lib/python/distutils/unixccompiler.pyc /dev/null differ
binary files a/sys/lib/python/distutils/util.pyc /dev/null differ
binary files a/sys/lib/python/distutils/version.pyc /dev/null differ
binary files a/sys/lib/python/email/__init__.pyc /dev/null differ
binary files a/sys/lib/python/email/mime/__init__.pyc /dev/null differ
binary files a/sys/lib/python/encodings/__init__.pyc /dev/null differ
binary files a/sys/lib/python/encodings/aliases.pyc /dev/null differ
binary files a/sys/lib/python/encodings/ascii.pyc /dev/null differ
binary files a/sys/lib/python/encodings/latin_1.pyc /dev/null differ
binary files a/sys/lib/python/encodings/string_escape.pyc /dev/null differ
binary files a/sys/lib/python/encodings/utf_8.pyc /dev/null differ
binary files a/sys/lib/python/filecmp.pyc /dev/null differ
binary files a/sys/lib/python/fnmatch.pyc /dev/null differ
binary files a/sys/lib/python/ftplib.pyc /dev/null differ
binary files a/sys/lib/python/getopt.pyc /dev/null differ
--- a/sys/lib/python/getpass.py
+++ b/sys/lib/python/getpass.py
@@ -65,12 +65,20 @@
     msvcrt.putch('\n')
     return pw
 
-
 def default_getpass(prompt='Password: ', stream=None):
-    print >>sys.stderr, "Warning: Problem with getpass. Passwords may be echoed."
-    return _raw_input(prompt, stream)
+    try:
+        ctl = open("/dev/consctl", "w")
+        ctl.write("rawon")
+        ctl.flush()
+        buf = _raw_input(prompt, stream)
+        ctl.write("rawoff")
+        ctl.flush()
+        ctl.close()
+        return buf;
+    except:
+        buf = _raw_input(prompt, stream)
+    return buf
 
-
 def _raw_input(prompt="", stream=None):
     # A raw_input() replacement that doesn't save the string in the
     # GNU readline history.
@@ -79,6 +87,7 @@
     prompt = str(prompt)
     if prompt:
         stream.write(prompt)
+        stream.flush()
     line = sys.stdin.readline()
     if not line:
         raise EOFError
@@ -113,16 +122,6 @@
     # McMillan Installer, make sure we have a UNIX-compatible termios
     termios.tcgetattr, termios.tcsetattr
 except (ImportError, AttributeError):
-    try:
-        import msvcrt
-    except ImportError:
-        try:
-            from EasyDialogs import AskPassword
-        except ImportError:
-            getpass = default_getpass
-        else:
-            getpass = AskPassword
-    else:
-        getpass = win_getpass
+    getpass = default_getpass
 else:
     getpass = unix_getpass
binary files a/sys/lib/python/getpass.pyc /dev/null differ
binary files a/sys/lib/python/gettext.pyc /dev/null differ
binary files a/sys/lib/python/glob.pyc /dev/null differ
binary files a/sys/lib/python/gzip.pyc /dev/null differ
binary files a/sys/lib/python/hashlib.pyc /dev/null differ
binary files a/sys/lib/python/heapq.pyc /dev/null differ
binary files a/sys/lib/python/hgext/__init__.pyc /dev/null differ
binary files a/sys/lib/python/hgext/bookmarks.pyc /dev/null differ
binary files a/sys/lib/python/httplib.pyc /dev/null differ
binary files a/sys/lib/python/inspect.pyc /dev/null differ
binary files a/sys/lib/python/linecache.pyc /dev/null differ
binary files a/sys/lib/python/locale.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/__init__.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/ancestor.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/archival.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/bundlerepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/byterange.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/changegroup.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/changelog.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/cmdutil.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/commands.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/config.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/context.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/copies.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/demandimport.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/dirstate.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/dispatch.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/encoding.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/error.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/extensions.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/fancyopts.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/filelog.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/filemerge.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/graphmod.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hbisect.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/help.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hg.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/__init__.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/common.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/hgweb_mod.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/hgwebdir_mod.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/protocol.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/request.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/server.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/webcommands.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hgweb/webutil.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/hook.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/httprepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/i18n.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/ignore.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/keepalive.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/localrepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/lock.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/manifest.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/match.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/mdiff.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/merge.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/minirst.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/node.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/patch.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/posix.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/repair.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/repo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/revlog.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/simplemerge.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/sshrepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/sshserver.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/statichttprepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/store.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/streamclone.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/subrepo.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/tags.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/templatefilters.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/templater.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/transaction.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/ui.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/url.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/util.pyc /dev/null differ
binary files a/sys/lib/python/mercurial/verify.pyc /dev/null differ
binary files a/sys/lib/python/mimetools.pyc /dev/null differ
binary files a/sys/lib/python/mimetypes.pyc /dev/null differ
binary files a/sys/lib/python/new.pyc /dev/null differ
binary files a/sys/lib/python/opcode.pyc /dev/null differ
binary files a/sys/lib/python/optparse.pyc /dev/null differ
binary files a/sys/lib/python/os.pyc /dev/null differ
binary files a/sys/lib/python/pickle.pyc /dev/null differ
binary files a/sys/lib/python/pkgutil.pyc /dev/null differ
binary files a/sys/lib/python/posixpath.pyc /dev/null differ
binary files a/sys/lib/python/py_compile.pyc /dev/null differ
binary files a/sys/lib/python/random.pyc /dev/null differ
binary files a/sys/lib/python/re.pyc /dev/null differ
binary files a/sys/lib/python/rfc822.pyc /dev/null differ
binary files a/sys/lib/python/sha.pyc /dev/null differ
binary files a/sys/lib/python/shutil.pyc /dev/null differ
binary files a/sys/lib/python/site.pyc /dev/null differ
binary files a/sys/lib/python/socket.pyc /dev/null differ
binary files a/sys/lib/python/sre_compile.pyc /dev/null differ
binary files a/sys/lib/python/sre_constants.pyc /dev/null differ
binary files a/sys/lib/python/sre_parse.pyc /dev/null differ
binary files a/sys/lib/python/stat.pyc /dev/null differ
binary files a/sys/lib/python/string.pyc /dev/null differ
binary files a/sys/lib/python/struct.pyc /dev/null differ
binary files a/sys/lib/python/subprocess.pyc /dev/null differ
binary files a/sys/lib/python/tarfile.pyc /dev/null differ
binary files a/sys/lib/python/tempfile.pyc /dev/null differ
binary files a/sys/lib/python/textwrap.pyc /dev/null differ
binary files a/sys/lib/python/token.pyc /dev/null differ
binary files a/sys/lib/python/tokenize.pyc /dev/null differ
binary files a/sys/lib/python/traceback.pyc /dev/null differ
binary files a/sys/lib/python/types.pyc /dev/null differ
binary files a/sys/lib/python/urllib.pyc /dev/null differ
binary files a/sys/lib/python/urllib2.pyc /dev/null differ
binary files a/sys/lib/python/urlparse.pyc /dev/null differ
binary files a/sys/lib/python/warnings.pyc /dev/null differ
binary files a/sys/lib/python/weakref.pyc /dev/null differ
binary files a/sys/lib/python/xml/__init__.pyc /dev/null differ
binary files a/sys/lib/python/xml/etree/ElementPath.pyc /dev/null differ
binary files a/sys/lib/python/xml/etree/ElementTree.pyc /dev/null differ
binary files a/sys/lib/python/xml/etree/__init__.pyc /dev/null differ
binary files a/sys/lib/python/xml/etree/cElementTree.pyc /dev/null differ
binary files a/sys/lib/python/zipfile.pyc /dev/null differ