From bc4638d722c0e48cfd6bc4d8084b41445f987004 Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Sun, 9 Apr 2006 23:54:34 +0000 Subject: Fixed #1569 -- HttpResponse now accepts iterators. Thanks, Maniac git-svn-id: http://code.djangoproject.com/svn/django/trunk@2639 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/core/handlers/modpython.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'django/core/handlers/modpython.py') diff --git a/django/core/handlers/modpython.py b/django/core/handlers/modpython.py index eec35ff072..37499c6f06 100644 --- a/django/core/handlers/modpython.py +++ b/django/core/handlers/modpython.py @@ -162,7 +162,8 @@ def populate_apache_request(http_response, mod_python_req): for c in http_response.cookies.values(): mod_python_req.headers_out.add('Set-Cookie', c.output(header='')) mod_python_req.status = http_response.status_code - mod_python_req.write(http_response.get_content_as_string(settings.DEFAULT_CHARSET)) + for chunk in http_response.iterator: + mod_python_req.write(chunk) def handler(req): # mod_python hooks into this function. -- cgit v1.3