Project

General

Profile

Feature #16773 » patch2.diff

timcraft (Tim Craft), 04/10/2020 11:35 AM

View differences:

lib/net/http/header.rb
alias canonical_each each_capitalized
def capitalize(name)
name.to_s.split(/-/).map {|s| s.capitalize }.join('-')
name.to_s.split('-').map {|s| s.capitalize }.join('-')
end
private :capitalize
......
end
byte_range_set = $1
result = byte_range_set.split(/,/).map {|spec|
result = byte_range_set.split(',').map {|spec|
m = /(\d+)?\s*-\s*(\d+)?/i.match(spec) or
raise Net::HTTPHeaderSyntaxError, "invalid byte-range-spec: '#{spec}'"
d1 = m[1].to_i
(2-2/3)