Fix some issues in exception base class