From f58ea237f68e0329c726dfa16155f0db343c4491 Mon Sep 17 00:00:00 2001 From: filipe Date: Tue, 14 Aug 2007 02:16:17 +0000 Subject: Allows to suppress the Content-Length: header which send_status normally adds, by calling send_status(nil). git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/trunk@550 19e92222-5c0b-0410-8929-a290d50e31e9 --- lib/mongrel.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/mongrel.rb b/lib/mongrel.rb index 97833dc..6d080d3 100644 --- a/lib/mongrel.rb +++ b/lib/mongrel.rb @@ -444,7 +444,7 @@ module Mongrel def send_status(content_length=@body.length) if not @status_sent - @header['Content-Length'] = content_length unless @status == 304 + @header['Content-Length'] = content_length if content_length and @status != 304 write(Const::STATUS_FORMAT % [@status, HTTP_STATUS_CODES[@status]]) @status_sent = true end -- cgit v1.2.3-24-ge0c7