diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-11-11 17:23:48 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-11 17:23:48 -0500 |
commit | c44886011fbdbad5010a2e1a1afabf184484dc0d (patch) | |
tree | 05aa155b1f1aded633cd0b47c45662596b0c6735 /cmd2/cmd2.py | |
parent | d5916797620225391379ea40ae466bd7f496ff52 (diff) | |
parent | c04c160b5484a5587345d3e1eca0c43fae9260f5 (diff) | |
download | cmd2-git-c44886011fbdbad5010a2e1a1afabf184484dc0d.tar.gz |
Merge pull request #804 from python-cmd2/sane_fix
Fix bug where cmd2 ran 'stty sane' command when stdin was not a terminal
Diffstat (limited to 'cmd2/cmd2.py')
-rw-r--r-- | cmd2/cmd2.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py index 23f45024..e50d9512 100644 --- a/cmd2/cmd2.py +++ b/cmd2/cmd2.py @@ -1607,7 +1607,7 @@ class Cmd(cmd.Cmd): """Run the command finalization hooks""" with self.sigint_protection: - if not sys.platform.startswith('win') and self.stdout.isatty(): + if not sys.platform.startswith('win') and self.stdin.isatty(): # Before the next command runs, fix any terminal problems like those # caused by certain binary characters having been printed to it. import subprocess |