MOSCOW (Reuters) - A Russian court on Friday ordered the release of an aspiring actor whose prison sentence for injuring a police officer on the sidelines of an opposition protest sparked a public outcry over alleged police brutality and judicial injustice.

The release of Pavel Ustinov, pending the outcome of his appeal, is a rare reversal by the Russian judicial system and follows a groundswell of public support for the 23-year-old.

But others sentenced in connection with a summer of Moscow protests calling for free elections remain behind bars, and Ustinov’s case is seen by some opposition activists as a way of de-escalating tensions with Kremlin critics while avoiding making bigger concessions.

Footage of his arrest on Aug. 3, which went viral, showed him scrolling through his mobile phone as he stood near a Moscow metro station, apparently minding his own business, as police disperse an opposition protest nearby.

Four national guardsmen in full riot gear are then seen suddenly grabbing Ustinov, pushing him to the ground, and beating him with their truncheons before marching him off. One of the guardsmen is seen falling over in the melee.

Ustinov said he’d not been taking part in the nearby protest, one of several held this summer to demand free elections to the Russian capital’s assembly.

His protests fell on deaf ears however and a court on Monday sentenced him to three and a half years in prison after finding him guilty of hurting the guardsman who fell. State prosecutors had wanted a harsher sentence of six years.

FILE PHOTO: Defendant Pavel Ustinov, accused of using violence against a police officer during an unauthorized rally to demand free elections, attends a court hearing in Moscow, Russia September 16, 2019. REUTERS/Evgenia Novozhenina/File Photo

Anger over what many saw as a glaring injustice swiftly bubbled over, with Russian celebrities, including those who work on Kremlin-backed state TV, taking to social media to demand Ustinov be freed.

Hundreds of others, including fellow actors, took turns to demonstrate outside the presidential administration and, as time wore on, others, including a senior figure in the ruling pro-Putin United Russia party, spoke out in his favour.

As pressure grew, state prosecutors, the same ones who had asked a court to jail him for six years, suddenly said they thought it was safe for Ustinov to be freed, on condition he did not leave Moscow.

LEGAL U-TURN

A Moscow court on Friday duly ordered Ustinov’s release from custody until an appeal against his sentence, due on Thursday next week, is heard. He was freed hours later, Russian news agencies reported.

His supporters said other people who had also been unjustly jailed were still languishing behind bars and needed to be released too.

The Kremlin said Ustinov’s case was a matter for the courts and it couldn’t intervene. When asked if it was surprised that prosecutors had such a dramatic change of heart, Kremlin spokesman Dmitry Peskov said “no”.

Ustinov was one of a handful of people jailed in connection with this summer’s protests that flared after the authorities barred opposition candidates from running in a Moscow election.

The rallies were the largest sustained protest movement in the Russian capital in years, peaking at around 60,000 people, before appearing to lose momentum. Another protest is planned later this month.

Kremlin critics have accused the courts of handing down harsh sentences to protesters to deter would-be sympathisers, something the authorities deny.