Libyan Prime Minister Abdulhamid al-Dbeibah has survived an apparent assassination attempt by unknown assailants.
Several rounds struck his car as it was being driven through the capital, Tripoli, early on Thursday.
The gunmen fled the scene.
Rival factions have been vying for control of Libya, and a parliament based in the east of the country is to vote later on Thursday on a replacement prime minister for a government of national unity.
Mr Dbeibah has said he will ignore the outcome of the ballot.
An election to choose a new government was postponed last December but no vote is now expected this year.