fixed unsafe use of string reference

The StringRef + Twine caused a segfault in a release build for me. According to
[1], this was unsafe.

[1] http://llvm.org/docs/ProgrammersManual.html#dss-twine