In power, the YSP was beset by internal divisions. In 1980 Ismail was replaced as President of South Yemen by Ali Nasir Muhammad, who was a more moderate and conciliatory leader compared to the pro-Soviet leftism of Ismail. He sought to improve relations with South Yemen's Arab neighbours and the West. Conflict between the two factions led to the South Yemen Civil War in 1986 which led to the death of Abdul Fattah Ismail, although his ally Ali Salem al Beidh took control of the party, while the more moderate Haidar Abu Bakr al-Attas became president. Al-Beidh and al-Attas would occupy positions in the government of a reunified Yemen until the 1994 civil war. Parliamentary elections were held in October 1986, and although the YSP remained the sole legal party, independent candidates were allowed to contest the elections, winning 40 of the 111 seats, with the YSP winning the other 71.