aboutsummaryrefslogtreecommitdiffstats
path: root/lib/webrick/httpresponse.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/webrick/httpresponse.rb')
-rw-r--r--lib/webrick/httpresponse.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/webrick/httpresponse.rb b/lib/webrick/httpresponse.rb
index bc1dacc837..41a2510e6f 100644
--- a/lib/webrick/httpresponse.rb
+++ b/lib/webrick/httpresponse.rb
@@ -254,7 +254,7 @@ module WEBrick
@header.delete('content-length')
elsif @header['content-length'].nil?
unless @body.is_a?(IO)
- @header['content-length'] = @body ? @body.bytesize : 0
+ @header['content-length'] = (@body ? @body.bytesize : 0).to_s
end
end
@@ -277,7 +277,7 @@ module WEBrick
# Location is a single absoluteURI.
if location = @header['location']
if @request_uri
- @header['location'] = @request_uri.merge(location)
+ @header['location'] = @request_uri.merge(location).to_s
end
end
end