China’s legislature voted overwhelmingly to end the presidential term limit, opening the way for President Xi Jinping to rule indefinitely.