Author: mattip <matti.pi...@gmail.com>
Branch: 
Changeset: r72123:4e8d7e49de5b
Date: 2014-06-21 22:48 +0300
http://bitbucket.org/pypy/pypy/changeset/4e8d7e49de5b/

Log:    fix test of rzipfile on win32 (arigato)

diff --git a/rpython/rlib/streamio.py b/rpython/rlib/streamio.py
--- a/rpython/rlib/streamio.py
+++ b/rpython/rlib/streamio.py
@@ -37,7 +37,7 @@
 import os, sys, errno
 from rpython.rlib.objectmodel import specialize, we_are_translated
 from rpython.rlib.rarithmetic import r_longlong, intmask
-from rpython.rlib import rposix
+from rpython.rlib import rposix, nonconst
 from rpython.rlib.rstring import StringBuilder
 
 from os import O_RDONLY, O_WRONLY, O_RDWR, O_CREAT, O_TRUNC, O_APPEND
@@ -159,6 +159,8 @@
             stream = TextInputFilter(stream)
     elif not binary and os.linesep == '\r\n':
         stream = TextCRLFFilter(stream)
+    if nonconst.NonConstant(False):
+        stream.flush_buffers()     # annotation workaround for untranslated 
tests
     return stream
 
 
_______________________________________________
pypy-commit mailing list
pypy-commit@python.org
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to