An appellate court in Brazil has cleared U.S. swimmer Ryan Lochte of a charge stemming from an incident last summer at the Olympics in Rio de Janeiro.

The Criminal Justice Court of the state of Rio de Janeiro dismissed the criminal case against Lochte, who was charged with falsely reporting a crime to police.

Lochte, a six-time Olympic gold medalist, was suspended from the sport last summer after he and three other swimmers -- Jimmy Feigen, Jack Conger and Gunnar Bentz -- vandalized a gas station during the Rio Games. In a television interview, Lochte said they had been robbed at gunpoint.

A three-judge panel voted 2-1 to close the case Thursday, according to court documents.

Brazilian network O Globo reported that the judges dropped the charge because Lochte's interview with NBC News the day after the incident did not constitute a false report.

"We are pleased that the court has finally dismissed the criminal prosecution against Mr. Lochte, while at the same time, appropriately recognizing that he committed no crime. It has been a long year, but in the end, justice prevailed," said Jeff Ostrow, Lochte's Florida-based attorney, in a statement to USA Today Sports on Friday.

Prosecutors have 15 days to decide whether they will challenge the ruling, according to USA Today. Under Brazilian law, the penalty for filing a false crime report is a maximum of 18 months in prison.

The scandal, which started Aug. 16 in Rio, overshadowed the final days of the Games, and the ever-changing version of events that Lochte provided cost him major sponsors.

Lochte, who apologized for his behavior, returned to the United States two days after the incident. Feigen followed the following day but only after reaching a deal with a judge to make a $10,800 payment. When Bentz and Conger boarded a plane to leave Rio, authorities removed the pair from the jet; police were not satisfied with their account of the robbery-that-wasn't and wanted more information. Bentz and Conger talked with authorities, were whisked through airport security and returned to the U.S. the next day.

In a follow-up interview with NBC News a week after the incident, Lochte said he "overexaggerated" what happened that night and acknowledged that it was his "immature behavior" that got him and his teammates into a mess that consumed the final week of the Olympics.

Lochte was set to return to USA Swimming competition this week for the first time since his 10-month suspension ended, but he reportedly withdrew from this weekend's L.A. Invitational, citing insufficient training due to the June birth of his son.

Information from The Associated Press was used in this report.