In 1954, the United States began selling arms to Pakistan while refusing an Afghan request to buy arms out of the fear that the Afghans would use any weapons they had purchased against America's ally Pakistan. As a consequence, Afghanistan, though officially neutral in the Cold War, drew closer to India and the Soviet Union, which unlike the United States, was willing to sell Afghanistan weapons. In 1962, China defeated India in a border war, and as a result, China formed an alliance with Pakistan against their common enemy, India. The Sino-Pakistani alliance pushed Afghanistan even closer to India and the Soviet Union.