OS-549, unused exceptions removed, code refactored