SRINAGAR, India Pakistani soldiers crossed the cease-fire line in the disputed Himalayan region of Kashmir on Tuesday and attacked an army patrol, killing two Indian soldiers before retreating back into Pakistani-controlled territory, an Indian army official said.

The outbreak of violence was the second in three days in Kashmir, where a cease-fire has largely held for a decade between the two wary, nuclear-armed rivals. Deaths in military exchanges are now extremely rare. But while diplomatic nervousness over the disputed region is never far from the surface, the earlier incident created no signs of escalating tensions.

The countries have fought two full-scale wars over Kashmir, the only Muslim-majority state in largely Hindu India.

Brig. S. Chawla, an Indian army spokesman, said the Pakistani soldiers crossed into Indian-controlled Kashmir near the town of Mendhar, about 110 miles (175 kilometers) from Srinagar, the region's main city, taking advantage of thick fog. The Pakistani soldiers retreated after a brief gun battle with Indian forces, he said.

"They not only violated the cease-fire, but also the sanctity of the line of control" that divides Kashmir, Chawla said.

Pakistani military officials could not be immediately reached for comment.

Kashmir is claimed in its entirety by both India and Pakistan, but divided between them.

While the two nations remain rivals, relations between them have improved dramatically since the 2008 Mumbai terror attacks, in which 10 Pakistani gunmen killed 166 people. India claims the terrorists had ties to Pakistani intelligence officials; an accusation that Islamabad denies.

In December, the two countries announced new visa rules designed to make cross-border travel easier. They have also been taking steps to facilitate trade.