@tenderlove I followed the comments in #5738 trying to repro the issue.

I was able to repro it with an app that uses Rails edge, on Fedora 20 with mariadb (mysql 5.5 plus patches). The app-specific code is in the commit below, the repo has the whole app.
https://github.com/pwnall/rails5738/commit/b06914fa86262cdd5176bb005844134129121e05

The key part to getting the repro was setting `encoding: latin1` in `database.yml`.

I wrote the test case like that because I thought it'd be overkill to set up a new database on latin1 just for this one bug. Sorry for being confusing.