c = EncodingUtils.encUintChr(context, (int) ((RubyBignum) c).getLongValue(), fptr.readEncoding(runtime));
} else {
c = c.convertToString();
}
if (fptr.needsReadConversion()) {
fptr.SET_BINARY_MODE();
len = ((RubyString) c).size();
// #if SIZEOF_LONG > SIZEOF_INT
// if (len > INT_MAX)
// rb_raise(rb_eIOError, "ungetc failed");
// #endif