BEIJING -- President Donald Trump has reaffirmed America’s long-standing “one China” policy in a phone call with Chinese President Xi Jinping, potentially alleviating concerns about a major shift in Washington’s relations with Beijing.

The White House and China’s state broadcaster CCTV said the two spoke at length by phone on Thursday evening.

The two leaders discussed numerous topics and Trump agreed “at the request of President Xi” to honor the “one China” policy that requires Washington to maintain only unofficial ties with China’s rival Taiwan, the White House said.

Get Breaking News Delivered to Your Inbox

CCTV reported that Xi “praised” Trump’s affirmation and said China was willing to work with the U.S. to enhance ties and bring “more fruitful gains for the benefit of our two peoples and those in every country.”

The White House described the call as “extremely cordial” and said the two leaders had invited each other to visit their respective countries and looked forward to further discussions.

Some had questioned why Trump had taken so long to call Xi given that he’d already spoken with more than a dozen world leaders. Chinese observers had also noted that Trump had broken with his predecessors in not extending good wishes to the Chinese people on the occasion of last month’s Lunar New Year holiday, prior to the issuing of a belated greeting on Wednesday.

Trump has accused Beijing of unfair trade practices, criticized China’s military buildup in the South China Sea and said Beijing is doing too little to pressure North Korea over its nuclear and missile programs.

China claims Taiwan as its own territory and complained after Trump upset decades of diplomatic precedent by talking by phone with Taiwanese President Tsai Ing-wen shortly after winning November’s presidential election.

In December, Trump said in an interview that he didn’t feel “bound” by the decades-old one China policy unless the U.S. could gain concessions from China in trade and other areas. Washington has robust unofficial relations with the island and provides it with arms to guard against Beijing’s threat to use force to reunify with it.

Underscoring uncertainty in the relationship, the call between the leaders came as the U.S. Pacific Command reported a Chinese jet and a U.S. Navy patrol plane had an “unsafe” encounter over the South China Sea this week.

Pacific Command spokesman Robert Shuford said Friday that the “interaction” between a Chinese KJ-200 early warning aircraft and a U.S. Navy P-3C plane took place on Wednesday in international airspace. He did not say what was unsafe about the encounter.

Shuford says the U.S. plane was on a routine mission and operating according to international law.

The Chinese defense ministry has not responded to a faxed request for comment.

China routinely complains about U.S. military surveillance missions close to its southern island province of Hainan, which is home to numerous sensitive military installations.

A collision between a U.S. EP-3 surveillance plane and a Chinese naval air force jet in April 2001 resulted in the death of the Chinese pilot and the 10-day detention of the U.S. air crew by China.