send proper 416 responses
commit89e1f00cd540bca54c2cbcb7d9b6cad5e0e3cf34
authorEric Wong <normalperson@yhbt.net>
Wed, 5 Jan 2011 18:22:11 +0000 (5 10:22 -0800)
committerEric Wong <normalperson@yhbt.net>
Wed, 5 Jan 2011 18:22:11 +0000 (5 10:22 -0800)
tree90500052feb9efaaa15a848fd58bf7bc84c248fe
parent429e9948d91fa159c2daa9944a5026cebb78bade
send proper 416 responses

416 responses without a body should respond with a zero
Content-Length and a Content-Range that allows clients
to specify a proper range in the future.

rfc2616, section 14.16 says:
> A server sending a response with status code 416 (Requested
> range not satisfiable) SHOULD include a Content-Range field
> with a byte-range- resp-spec of "*". The instance-length
> specifies the current length of the selected resource.
lib/rainbows/response.rb
t/byte-range-common.sh