DR Congo, the winners of the inaugural African Nations Championship, will clash with Ghana in Sunday’s quarter-finals after they finished behind Gabon in Group D.
On Wednesday, DRC beat Burundi 2-1 at Polokwane to finish on six points, a point behind Gabon, whose three goals in the last five minutes saw them dump Mauritania 4-2.
Group winners Gabon will now face Libya, runners-up in Group C, also on Sunday.
DRC had to come back from a 14th minute strike by Burundi skipper Selemani Ndukumana thanks to a brace by Makusu Mundele in the 24th and 37th minutes.
The winners of the 2009 tournament in the Ivory Coast, who paraded several players from four-time African champions TP Mazembe, had to draw on their wealth of experience to subdue a youthful Burundi side.
Debutants Mauritania took a shock lead after just four minutes in Bloemfontein through Moulaye Ahmed Khalil, before Duval Nzembi restored parity for Gabon three minutes later.
Mauritania regained the lead in the 65th minute through Ahmed Khalil, before Gabon, led by veteran striker Daniel Cousin, staged a late fight back to score three goals.
Aaron Appindangoye drew them level in the 85th minute and Bonaventure Sokambi delivered a brace in stoppage time, including a penalty, to catapult them to the top of the group.