fixed exception handlers