Fix segfault when using flat fonts.