Bosnia & Herzegovina were pushed to the limit by Bulgaria but survived 75-71 in overtime to get their additional qualifying tournament for EuroBasket 2007 on track.
In a battle of national sides that played at the EuroBasket two years ago, hosts Bosnia & Herzegovina looked to be on their way to victory midway after going on a 7-0 run to lead 65-58 with 2:33 remaining.
The Bulgarians battled back and tied the contest at 65-65 with 1:15 remaining on a Todor Stoykov three ball.
With the score still the same, Stoykov had a chance to win with four seconds to go but his tap-in off a missed shot stayed out.
Bosnia & Herzegovina moved in front for good at the start of the extra period.
Kenan Bajramovic, a star with Azovmash in this season's EuroCup, made a jump shot at the start of overtime to spark a 5-0 surge.
Though Bulgaria closed the gap to 70-68 and 72-70, they would get no closer.
Sasa Vasiljevic had 21 points and Bajramovic 15 to place the hosts, while Dimitar Angelov poured in 16 and Stoykov 15 for Bulgaria.