From 6c405b9d14e67418b394d5312c297e9e8d9012b1 Mon Sep 17 00:00:00 2001 From: Benoit Chesneau Date: Wed, 3 Feb 2010 10:32:28 +0100 Subject: [PATCH] fix issue #7. thanks! --- gunicorn/util.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gunicorn/util.py b/gunicorn/util.py index fdf95cb8..d3af4a86 100644 --- a/gunicorn/util.py +++ b/gunicorn/util.py @@ -93,7 +93,7 @@ def writelines(sock, lines): for line in list(lines): write(sock, line) -def write_error(sock, mesg): +def write_error(sock, msg): html = textwrap.dedent("""\ @@ -105,7 +105,7 @@ def write_error(sock, mesg):
%s
- """) % mesg + """) % msg http = textwrap.dedent("""\ HTTP/1.0 500 Internal Server Error\r Connection: close\r @@ -113,7 +113,7 @@ def write_error(sock, mesg): Content-Length: %d\r \r %s - """) % (len(http), http) + """) % (len(html), html) write_nonblock(sock, http) def normalize_name(name):