The aircraft, carrying 181 people, veered off the runway and burst into flames after it hit a fence when the landing gear malfunctioned.