FILE PHOTO: Brazil's presidential candidate Jair Bolsonaro sits on a plane in Sao Paulo, Brazil September 29, 2018. REUTERS/Leonardo Benassatto

BRASILIA (Reuters) - Brazilian far-right presidential candidate Jair Bolsonaro has changed his mind and will accept the result of this month’s election even if the leftist Workers Party (PT) wins, his running mate said on Monday.

Bolsonaro, a former army officer who has expressed admiration for Brazil’s 1964-1985 military dictatorship, said on Friday that he would not accept defeat. Opinion polls show him winning the most votes in Sunday’s first round but losing to the PT’s Fernando Haddad in a probable run-off three weeks later.

“He has changed that view. If he is defeated, he loses,” retired General Hamilton Mourão told reporters at Brasilia airport.

Bolsonaro has previously accused the PT of planning to rig the elections, which some Brazilians have interpreted as a warning intended to encourage a military coup if he did not win.

Mourão said Brazil’s military would “logically” accept a PT victory, even if that meant, in his view, a return to incompetent government and corruption.

“The armed forces are sitting quiet, following their commanders,” the general said.

Mourão was relieved of his military command in 2015 and given a staff job after he publicly criticized then PT President Dilma Rousseff. Last year, he suggested that the military should take over if Brasilia’s courts failed to stop political corruption.

Brazil’s most polarized election since the return to civilian government in 1985 is heading for a close race between the right and the left, according to the polls.

If neither Bolsonaro nor Haddad win a majority of the vote in the first round, a run-off between the two top candidates will be held on Oct. 28. Major polling firms Ibope and Datafolha have found Haddad would likely win.