Not necessarily. Institutes will assess your academic background comprehensively and they will weigh the recent years more. Therefore, if you failed a subject in your first year but you obtained fairly good results recently, the impact will be limited.
However, for onshore student, if your failure resulted in breach of student visa condition, institutes may refuse your application.