Suppress surrogate character segfault.

See issue 1026.