BEIJING (AP) — Chinese leader Xi Jinping was handed a third five-year term as president Friday, putting him on a path to staying in power for life.

The endorsement of Xi’s nomination by the ceremonial National People’s Congress was a foregone conclusion for a leader who has sidelined potential rivals and packed the highest ranks of the ruling Communist Party with his supporters since taking power in 2012.

The vote in favor of Xi was 2,952 to 0 by the NPC, whose members are appointed by the ruling party.

Xi, 69, appointed himself to a third five-year term as party general secretary in October, breaking with a tradition that Chinese leaders handed over power once a decade. Earlier, a two-term limit for the figurehead presidency was removed from the Chinese constitution, prompting suggestions he could stay in power for life.

No candidate lists were distributed and Xi and others were believed to have run unopposed. For the most part, the electoral process remains shrouded in secrecy.

Xi was also unanimously appointed commander of the 2 million-member People’s Liberation Army, a force that explicitly takes its orders from the party, not the country.