bugfix of handling error_reporting.