Add missing check to av_get_token().