make fgetwc set error indicator for stream on encoding errors