[Python-checkins] r87814 - peps/trunk/pep-3333.txt
phillip.eby
python-checkins at python.org
Fri Jan 7 05:29:15 CET 2011
Author: phillip.eby
Date: Fri Jan 7 05:29:14 2011
New Revision: 87814
Log:
Make CGI example correct for Py3
Modified:
peps/trunk/pep-3333.txt
Modified: peps/trunk/pep-3333.txt
==============================================================================
--- peps/trunk/pep-3333.txt (original)
+++ peps/trunk/pep-3333.txt Fri Jan 7 05:29:14 2011
@@ -315,8 +315,8 @@
sys.stdout.write('%s: %s\r\n' % header)
sys.stdout.write('\r\n')
- sys.stdout.write(data) # TODO: this needs to be binary on Py3
- sys.stdout.flush()
+ sys.stdout.buffer.write(data)
+ sys.stdout.buffer.flush()
def start_response(status, response_headers, exc_info=None):
if exc_info:
More information about the Python-checkins
mailing list