summaryrefslogtreecommitdiffstats
path: root/Lib/pydoc.py
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2014-06-08 03:17:29 (GMT)
committerBenjamin Peterson <benjamin@python.org>2014-06-08 03:17:29 (GMT)
commiteac219436c0503968b47b7e316a2c1a72ed823f7 (patch)
treea31c889996c183349d837dd9f398d0d7a233a537 /Lib/pydoc.py
parent10e847bbc7427e85f38191298275eaf14be625e5 (diff)
parent159824ea2a1872dadef69a229fb294c571d2ac73 (diff)
downloadcpython-eac219436c0503968b47b7e316a2c1a72ed823f7.zip
cpython-eac219436c0503968b47b7e316a2c1a72ed823f7.tar.gz
cpython-eac219436c0503968b47b7e316a2c1a72ed823f7.tar.bz2
merge 3.4 (#11709)
Diffstat (limited to 'Lib/pydoc.py')
-rwxr-xr-xLib/pydoc.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/pydoc.py b/Lib/pydoc.py
index cb65aef..adb15c4 100755
--- a/Lib/pydoc.py
+++ b/Lib/pydoc.py
@@ -1415,6 +1415,8 @@ def pager(text):
def getpager():
"""Decide what method to use for paging through text."""
+ if not hasattr(sys.stdin, "isatty"):
+ return plainpager
if not hasattr(sys.stdout, "isatty"):
return plainpager
if not sys.stdin.isatty() or not sys.stdout.isatty():