[pypy-commit] pypy py3k_add_terminal_size: Fix translation.

marky1991 pypy.commits at gmail.com
Thu Aug 25 03:36:16 EDT 2016


Author: Mark Young <marky1991 at gmail.com>
Branch: py3k_add_terminal_size
Changeset: r86526:8af26ef17f86
Date: 2016-08-24 22:42 -0400
http://bitbucket.org/pypy/pypy/changeset/8af26ef17f86/

Log:	Fix translation.

diff --git a/pypy/module/posix/interp_posix.py b/pypy/module/posix/interp_posix.py
--- a/pypy/module/posix/interp_posix.py
+++ b/pypy/module/posix/interp_posix.py
@@ -2147,7 +2147,7 @@
    
 def get_terminal_size(space, w_fd=None):
     if w_fd is None:
-        fd = rfile.c_fileno(rfile.c_stdout)
+        fd = rfile.RFile(rfile.c_stdout(), close2=(None, None)).fileno()
     else:
         if not space.isinstance_w(w_fd, space.w_int):
             raise oefmt(space.w_TypeError,


More information about the pypy-commit mailing list