Stopgap for unicode chars in filename strings

Such filenames still can't be matched against, but at least we won't throw an
exception when it happens.

Fixes #279, relevant to #278