President Dilma Rousseff of Brazil has vetoed part of a law intended to share royalties from Brazil's oil fields across the country's 26 states.
Rio de Janeiro governor Sergio Cabral earlier warned the measure could bankrupt his state before the next Olympics in 2016 and the 2014 FIFA World Cup.
President Rousseff vetoed part of the legislation which would have affected existing oil concessions. But she retained a measure spreading wealth from fields which are still to be auctioned.
Some 200,000 people earlier protested in Rio de Janeiro against the bill, which politicians had said it could cost the state $US1.7 billion next year.
Brazil's main oil-producing states had threatened legal action over the measure.
The BBC reports a new method for distributing royalties has to be in place by January in order for auctions of explorations blocks to go ahead.