Senegal beat Sudan on penalties on Friday to finish third in the African Nations Championship (CHAN).
The victory gave the defending champions a small measure of consolation after they lost their semi-final to Morocco.
Sudan took an early lead in the sixth minute before Seyni Ndiaye equalised for Senegal in the 58th minute in the match played in front of a lively crowd in Uganda’s capital, Kampala.
The West Africans dominated possession, but Sudan held on to push the contest to penalties with extra-time absent in the third-place play-off.
Senegal were on target in four penalties against Sudan's two.
“The players showed maturity after the disappointment of the semi-final. We wanted to finish with something, and we did that,” Senegal's coach Souleymane Diallo is quoted as saying by the Confederation of African Football (CAF) website.
Sudan were competing in the third-place play-off for a record third time, while Senegal were making their second appearance.
Morocco and Madagascar will play in the final in Kenya's capital, Nairobi, on Saturday.
The championship is reserved for players who play in their domestic leagues.
