Improve error return by checking the FAILURE status.