China and Vietnam have agreed to seek a long-term resolution to a territorial dispute in the South China Sea that has stoked tensions between the two countries. A six-point agreement, signed on Tuesday by Vice-Foreign Minister Zhang Zhijun and his Vietnamese counterpart, Ho Xuan Son, and posted on the Ministry of Foreign Affairs' website yesterday, said it was in accordance with a consensus reached by the countries' leaders and based on a 1993 agreement on basic principles for resolving bilateral territorial and border disputes. The two countries should remain committed to friendly consultations in order to properly handle maritime issues and make the South China Sea an area of peace, friendship and co-operation, the agreement said. The agreement was signed during a visit to China by the general secretary of the Vietnamese Communist Party, Nguyen Phu Trong, for conciliatory talks with President Hu Jintao, who is also Communist Party chief. China and Vietnam - as well as the Philippines, Brunei, Malaysia and Taiwan - have staked sovereignty claims over parts of the sea. Under the agreement, the two sides consented to set up a hotline to deal with potential maritime conflicts and hold border talks twice a year, with special meetings taking place when necessary. 'Both sides agreed to set up a hotline contact mechanism in order to allow them to promptly communicate and properly deal with maritime issues,' it said. It said that Beijing and Hanoi should solve maritime disputes through negotiations and friendly consultations, and they should consult with other countries if they were also involved in the disputes. The agreement calls for both sides to 'explore interim and temporary solutions' while seeking a long-term resolution, saying the bridge-building effort could dispel rancour that has built up in the region. Ju Hailong, a Guangzhou-based expert in Sino-Vietnamese relations at Jinan University, said the agreement showed the countries' determination to maintain a stable and peaceful South China Sea, with Beijing using it to reiterate its peaceful policy in dealing with territorial disputes with its neighbours. Dr Zhang Mingliang, a deputy professor from the Institute of Southeast Asian Studies at Jinan University, said Beijing was also trying to deter Japan, which was becoming active in the disputed area, from any intervention because that would make disputes in the South China Sea - home to potentially rich oil and gas deposits and crossed by key shipping lanes - more complicated. 'Beijing realises that some Southeast Asian neighbours want to drag in the US and Japan to increase their bargaining chips on the negotiating table,' Zhang said, adding that Japan was seeking any opportunity to contain China. Japanese media reported that Tokyo was planning to set up a co-ordination mechanism for sovereignty negotiations in the South China Sea and free and safe navigation. Earlier reports said Japan had promised to share maritime intelligence with the Philippines and help Manila train and improve coastal defences. Sino-Vietnamese relations sank to their lowest point in years in May and June when Vietnam said Chinese vessels had twice interfered with oil-survey ships in the South China Sea. Both nations recently moved to calm tensions over the territorial dispute, agreeing to hold talks and ruling out military confrontation.