1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Small error on a rare condition.

git-svn-id: svn+ssh://rubyforge.org/var/svn/mongrel/trunk@329 19e92222-5c0b-0410-8929-a290d50e31e9
This commit is contained in:
zedshaw 2006-08-15 01:50:51 +00:00
parent 19a0c275a5
commit c8b6daadf5

View file

@ -200,9 +200,6 @@ module Mongrel
@body = StringIO.new
@body.write params.http_body
dispatcher.request_progress(params, 0, content_length) if dispatcher
elsif remain < 0
# ERROR, they're sending bad requests
raise HttpParserError.new("Sent body size #{params.http_body.length} but declared Content-Length: #{content_length}")
elsif remain > 0
# must read more data to complete body
if remain > Const::MAX_BODY
@ -218,7 +215,7 @@ module Mongrel
read_body(remain, content_length, dispatcher)
end
@body.rewind
@body.rewind if body
end