(Repeats with no changes to text)
By Anthony Boadle
BRASILIA, Dec 20 (Reuters) - Brazilian President Dilma Rousseff's key ally in Congress is certain it can head off an impeachment threat, but in return the party demands a radical change of policy course to pull the economy out of its deepest downturn in 25 years.
Senator Eunicio Oliveira, Senate leader of the fractious Brazilian Democratic Movement Party (PMDB), told Reuters on Sunday that Rousseff took a first step in that direction by replacing austerity-minded Finance Minister Joaquim Levy with leftist economist Nelson Barbosa, who is expected to ease up the belt-tightening to spur growth.
Levy threw in the towel after Brazil lost its hard-won investment grade last week.
Oliveira said Rousseff's position had improved with Supreme Court rulings on Wednesday that gave the upper chamber authority to reject impeachment even if the lower house votes to impeach her.
"A majority of PMDB senators are in favor of the president finishing her term," Oliveira said. "What they want is for her to change her economic policies to get the country growing again."
Oliveira said the opposition's case against Rousseff has no legal basis and is unlikely to fly in the Senate where her governing coalition has a solid majority and will stand by her.
His comments are a clear sign that Rousseff's allies from the moderate PMDB have lost patience with the austerity policies Levy advocated. Together with her own left-leaning Workers' Party, never a fan of Levy's agenda, that points to stronger support for a bid to restore growth sooner through government spending even at the risk of accelerating inflation.
In its economic agenda, the PMDB has rejected what it called fiscal austerity for the sake of austerity and advocated liberalizing labor laws and reforming of the pension system.
Brazil's deep recession and a massive corruption scandal at state-run oil company Petroleo Brasileiro SA have turned Rousseff into the country's most unpopular president in as many years, and her opponents are seeking to unseat her one year into her second term for allegedly breaking budget laws.
While the PMDB is often plagued by infighting and includes members who are staunch allies of Rousseff as well as some arch-enemies, Oliveira's stance as a senate leader can be seen as indicative of its mainstream.
"She has done nothing dishonest. Only the economic crisis can bring her down, by fueling social discontent," he said.
Impeachment proceedings against Rousseff were opened Dec. 2 in the lower house by her archenemy, the speaker Eduardo Cunha, a PMDB leader who has been charged with taking bribes. But on Wednesday, the Supreme Court ruled a secret vote Cunha used to stack an impeachment committee with lawmakers who want Rousseff ousted was invalid and needed to be held again.
The court also gave more power to the Senate to decide whether to hold an impeachment trial during which the president would have to step down.
Rousseff is believed to have a margin of about 20 votes in her favor to be able to block impeachment in the lower house, where her opponents deplored the Supreme Court rulings.
Yet even some of Rousseff's harshest critics are now acknowledging that the legislative math works against them.
"This rotten government that has been adrift since day one gained new oxygen from the court that practically buried the impeachment," said PMDB lawmaker Jarbas Vasconcellos.
Rousseff's prospects of political survival got a mild boost over the weekend from a poll that showed her approval rating has improved slightly.
Presidential aides worry, however, that rising inflation and the growing ranks of unemployed Brazilians - economists estimate unemployment could reach 10 percent next year - will reignite social unrest and fuel the anti-Rousseff movement as a decision on the impeachment process drags on into next year.
In his first comments as finance minister, Barbosa vowed to continue the fiscal adjustment started by Levy, including the implementation of an unpopular transactions tax, but he made it clear he will seek a faster road back to economic growth.
The choice of Barbosa, an advocate of spending on housing and other programs to stimulate the economy, is unlikely to win Rousseff friends on Wall Street. But the move is a calculated gamble that many in Brazil have lost their stomach for more belt-tightening and want to see growth return now, even at the risk of greater inflation later.
Less austerity will go down well with the ruling Workers' Party and labor unions that distanced themselves from Rousseff over Levy's policies but will become vital allies if street protests against her grow in size next year.
Now that Brazil has been downgraded, Rousseff wants to move on and redirect economic policy to save her presidency, said Gabriel Petrus, at consultancy Barral M Jorge in Brasilia. He said Barbosa might open up the state banks funding tap again.
"Like the market, Rousseff has priced in the loss of the investment grade. She is looking for positive economic results now," Petrus said. (Reporting by Anthony Boadle; Editing by Christian Plumb and Tomasz Janowski)