A court in Krakow, Poland has ruled against a US request to extradite the Oscar-winning film-maker Roman Polanski to the US over a 1977 child sex conviction.
The 82-year-old Polanski did not attend court on Friday morning "because of emotional reasons," his lawyer Jan Olszewski told the judge.
Prosecutors can appeal against the ruling.
Judge Dariusz Mazur has said that the request was "inadmissible."
Polanski was accused of having unlawful sex with a girl who was 13-years-old, giving the minor champagne and drugs at a photoshoot and taking topless photos of her in Los Angeles.
He pleaded guilty for having unlawful sex with a minor in 1977 and served 42 days in jail as part of a 90-day plea bargain, but fled from the US ahead of his sentencing in 1978.
In 2009, he was arrested in Zurich on a US extradition warrant and placed under house arrest for nine months.
He was released in 2010 after Swiss authorities rejected the extradition order.