Use sneaky trick to fix architectures where EOF doesn't fit in a char.