use `_check_rc(rc)` here