Sri Lanka’s August elections have been timed to stop a comeback by war-time president Mahinda Rajapaksa, who remarkably may see his popularity rise in coming months if criticized for war crimes in a U.N report, said government sources.

Rajapaksa’s crushing of a 26-year Tamil Tiger insurgency in 2009 won him support among the country’s Sinhalese majority and he still has a very strong following.

Thousands rallied to hear him announce his comeback campaign on a Buddhist holiday in his Hambantota district on July 1.

“He is popular and a strong campaigner among Sinhala masses with the war victory,” said Kusal Perera, director of the Center for Social Democracy, a Colombo-based think tank.

A U.N. report on the last days of the war is due for release in September but an aide to President Maithripala Sirisena said diplomatic sources had warned it may be leaked in late August.

The possibility of an early release prompted Sirisena to call elections for Aug. 17 to give his ally Prime Minister Ranil Wickremesinghe an edge and hopefully deny Rajapaksa any chance of a political resurgence, said sources close to Sirisena.

“Even if is not said openly, the U.N. report was considered when deciding the date,” Champika Ranawaka, power and energy minister and one of Sirisena’s close allies, told Reuters.

Foreign diplomatic sources said some Western countries also worried the U.N. report could help Rajapaksa and urged Sirisena not to delay elections.

Dissolving parliament for August elections has also saved Wickremesinghe from a scheduled no-confidence motion over alleged mismanagement of the economy.

INDIA, CHINA TIES AT STAKE

The outcome of the elections will also determine whether Sri Lanka under Sirisena continues to repair relations with India, or opts for greater ties with China under Rajapaksa.

Rajapaksa built close ties with China, helping Beijing establish a strategic foothold in the Indian Ocean to the chagrin of traditional ally India.

China built ports, airports, highways, and power plants under Rajapaksa with more than $5 billion in loans, and sent a submarine and warship to visit Colombo, irking India.

But Rajapaksa’s decade-long rule was marred by allegations of corruption and rights violations. Rajapaksa, some former ministers and family members now face multiple investigations. They have denied any wrongdoing.

Sirisena has been trying to reverse some of the steps Rajapaksa took to consolidate power, by depoliticising state institutions such as the police, judiciary and public services.

He has re-established ties with India, making India his first foreign visit, and questioned deals with China, including a $1.4 billion luxury property and port project.

“China has been trying to strengthen its relationship with the new government,” a top government official told Reuters.

Dullas Alahapperuma, a minister under Rajapaksa, said if Rajapaksa forms the next government the former president would resume all projects stopped by Sirisena.

RISK OF POLITICAL GRIDLOCK

Sirisena is a former minister in Rajapaksa’s administration who defected last year to become president, promising fresh elections in 2015.

But since taking office he has failed to pass electoral reforms due to opposition from his main ruling coalition partner, the United National Party, and members of his own Sri Lanka Freedom Party (SLFP), who remain loyal to Rajapaksa.

The rivalry between Sirisena and Rajapaksa at the upcoming elections may further splinter the SLFP, which has seen around 75 members join the opposition since January.

Sirisena has said he will not support Rajapaksa as the SLFP prime ministerial candidate, but he is under pressure due to Rajapaksa’s popularity to allow him to contest the elections under an SLFP-led opposition coalition.

“People have the confidence that if Mahinda Rajapaksa comes to power, national security would be his top priority … He is still the leader who won the war and brought the development to villages,” said Sehan Semage, a young parliamentarian.

SLFP divisions may splinter the vote and result in a hung parliament and further instability, say political analysts.

Last week, Rajapaksa expected some 80 SLFP legislators to show up in support when he announced plans for his comeback, according to senior party leader Alahapperuma.