(Fixes typo in first paragraph)
By Ashok Pahalwan
JAMMU, India, May 3 (Reuters) - A Pakistani prisoner was badly beaten in an Indian jail on Friday in apparent retaliation for a fatal attack on an Indian spy prisoner in Pakistan whose death has led to widespread anger and strained already fraught ties between the neighbours.
Sanaullah Haq was being treated for severe head injuries in the intensive care ward of a local hospital in the northern Indian state of Jammu and Kashmir, which borders Pakistan and has seen serious territorial disputes between the two nations.
"He was rushed to Jammu Medical College Hospital in critical condition as he had suffered severe head injury in the attack. We are making arrangements for critical care ambulance to shift him to Chandigarh or New Delhi for treatment," said Rajni Sehgal, superintendent of the Kotbawal jail where the attack happened.
Pakistan's foreign ministry said the incident was "condemnable" and called on India to punish the attacker. India's foreign ministry said it regretted the attack and promised to give consular access to Haq once his condition stabilized.
Sehgal said Haq had spent 17 years in Jammu prisons on murder charges for militancy related crimes. Sehgal said Haq was hit with a farming tool in the prison garden by a fellow prisoner in an argument over the death of the Indian prisoner who died in Pakistan, Sarabjit Singh. His attacker was a court-martialed member of the Indian army.
Nuclear-armed India and Pakistan have fought three wars since the partition of British-ruled India in 1947, although they began a peace process in 2004. They remain deeply suspicious of each other.
The assault came a day after the death of Singh, convicted of spying and bomb blasts in Pakistan. He was hospitalized last week after two inmates attacked him in jail in the eastern Pakistani city of Lahore. India's government and his family maintain he was an innocent farmer.
The India government accused Pakistan of not doing enough to protect Singh.
Protesters burned effigies depicting Pakistani President Asif Ali Zardari and demanded a halt to bus and train services to Pakistan on Thursday. On Friday, hundreds took to the streets in three Indian cities. Singh's home state of Punjab declared a three-day state of mourning.
Hundreds of people gathered in Singh's home town near the Pakistan border, where his funeral is due to be held later on Friday. Some shouted "Death to Pakistan."
Several Indian states beefed up security in their jails in an aim to protect Pakistani prisoners. Many states already keep Pakistani prisoners segregated from their Indian counterparts.
Last year, some 270 Indian prisoners, mostly fishermen, were in Pakistani jails.
The latest flare-up follows an outbreak of violence in Kashmir in January, where two Pakistani and two Indian soldiers were killed. It was the worst clash there since India and Pakistan agreed to a ceasefire nearly a decade ago, leading to angry reactions from both sides.
Despite the recent strains, India and Pakistan's relations have improved after nose-diving in 2008 when gunmen killed 166 people in Mumbai in a three-day rampage that India blamed on a Pakistani militant group. Last year, India hanged Pakistani citizen Ajmal Kasab, who was convicted of taking part in that attack. (Additional reporting by Fayaz Bukhari; Writing by Annie Banerji; Editing by Frank Jack Daniel and Michael Perry)