Fix some numeric and char conversions