fix exception error string handling