Update utils.rb to handle UTF-8 encoded strings

This is meant to address the warning that is showing up in the nginx error log:
/srv/airbnb/code0/vendor/bundle/ruby/1.9.1/gems/rack-1.2.7/lib/rack/utils.rb:16: warning: regexp match /.../n against to UTF-8 string

The code is modified from https://github.com/chneukirchen/rack/pull/14/files