England's forthcoming friendly with Brazil descended into farce when a judge reversed her ruling the Maracana stadium was unsafe to host the match.
The match was in doubt yesterday evening but Rio de Janeiro state government confirmed Judge Adriana Costa dos Santos did a U-turn despite initial safety fears.
A statement by the Rio state government confirmed the stadium complies with "all safety rules".
"All safety requirements for the friendly between Brazil and England have been complied with and, because of a bureaucratic failure, the appraisal from the public ministry that proves the compliance with the rules on safety at the Maracana have not been sent to Suderj," the statement read.
The uncertainty surrounding Sunday's match is further embarrassment for Brazilian sporting authorities after it was announced in March the João Havelange stadium, which will host the 2016 Olympics, would be closed indefinitely following concerns about its roof.
The renovation of the 78,000 seater Maracana was completed last month ahead of next year's 2014 World Cup, and the iconic arena will host the Confederations Cup's opening ceremony next month.
The judge's original decision came after a prosecutor submitted a request for the match to be cancelled because of a lack of assurances work on the stadium had been finalised, with worries that debris left over by construction workers could be hurled in the case of a disturbance. There were also reports that there could be a problem with flooring.
The judge was quoted by newspaper Estado as saying: ''Despite numerous requests from the public ministry (the state prosecutor), the reports were not delivered in their entirety and we do not have at this moment the proof the stadium meets the minimum requirements necessary to put on matches or events.
''Because of the inaction of those responsible, there is no way we can allow the stadium to be reopened without the proof that it is in satisfactory conditions for hygiene and safety.''
England yesterday trained at Copacabana beach ahead of the game, which will kick-off at 8.00pm GMT.