econsultancy/rails — pull request #1 by lmars (2012-11-29 20:04:59+00:00)
Title: Utf 8 fixes without changes to routing redirect method

This is a backport of https://github.com/rails/rails/commit/66eb3f02cc0894f08c4f912ba8bf6fb1f87e9a4a and https://github.com/rails/rails/commit/3fc561a1f71edf1c2bae695cafa03909d24a5ca3 to fix "ArgumentError: invalid byte sequence in UTF-8" errors when invalid UTF-8 is used in HTTP requests.

**NOTE** this does not include the change to `actionpack/lib/action_dispatch/routing/redirection.rb` as it did not cherry-pick easily