handle POLL_ERR first