Two high court judges in Bangladesh have ruled that the detention of a prominent journalist, Shahriar Kabir, on sedition charges is unlawful.

But they ruled that it was not within their power to give him bail.

Mr Kabir was imprisoned last month after returning from a visit to India in which he filmed Hindu refugees who allegedly fled Bangladesh to escape persecution from Islamic extremists.

The government says Mr Kabir's activities have undermined the sovereignty of Bangladesh, but his lawyers say that he is a political prisoner forced to endure appalling conditions in jail.

Expose

Mr Kabir's lawyers say that his imprisonment shows that press freedom in Bangladesh is under threat.

Hundreds of Hindus are said to have fled Bangladesh following persecution

They say that his only crime was to expose the plight of Bangladesh's Hindu minority by filming them in refugee camps in India.

Many Hindus say they have been force to flee Bangladesh to escape communal violence following the election of a new government in October which contains two hard-line Islamic parties.

After the court ruling on Saturday, lawyers for Mr Kabir say they intend to return to court as soon as possible to try and get him released.

They say that because they are denied access to him in jail, it is not clear whether he will be informed of the court ruling in his favour.

Meanwhile concerns about his health, including a heart condition, have worsened during his time in jail.

Criticism

Mr Kabir faces life imprisonment if he is found guilty of the charges levelled against him, which includes sedition, and undermining the sovereignty of the state.

The rise of Islamist influence has concerned minorities

Some of the charges stem from an interview which he gave to the BBC in India.

Human rights groups, including Amnesty International, have condemned his imprisonment, describing him as a prisoner of conscience.

His lawyers say the case should never come to trial, and that the only reason he is in the dock is because he is seen as close to the opposition, and has been strongly critical of the hardline Jamiat-e-Islami party, which is now part of the government.

But the prosecution argues that he is a troublemaker rather than a political prisoner, and that he faces such serious charges because he has publicly questioned the independence of Bangladesh in violation of the country's constitution.

The government also accuses Mr Kabir of unfairly accusing individual ministers of collaborating with Pakistan during Bangladesh's war of independence in 1971.