Nigeria became the first qualifiers for the second round of the Africa Cup of Nations when they beat Guinea 1-0 in Alexandria on Wednesday with Kenneth Omeruo scoring the only goal.
Centre-back Omeruo headed a corner into the net on 73 minutes to earn the Super Eagles a second straight Group B victory after beating Burundi by the same score four days ago.
Nigeria have a maximum six points, Madagascar and Guinea one each and Burundi are pointless in the group. The Burundians and Malagasies meet on Thursday.
Although the Super Eagles are not guaranteed to finish first, they are certain of a top-two finish and a place in the next round.
Guinea star Naby Keita started his first match since being injured playing for Liverpool at Barcelona in a Champions League semi-final last month.
He received some rough treatment and was substituted midway through the second half just before Nigeria broke the deadlock.
Samuel Kalu, who collapsed while training last Friday with severe dehydration, replaced Moses Simon deep in stoppage time.
Although the countries have made 30 appearances between them at the Cup of Nations, this was only the second time they had met, the first was a 1-1 draw in Ethiopia 43 years ago.
Both coaches had been unhappy with their first outings against debutants, as Nigeria pipped Burundi 1-0 and Guinea led and trailed in a 2-2 draw against Madagascar.
Nigeria's German coach Gernot Rohr made five changes, including dropping veteran captain John Obi Mikel with Ahmed Musa wearing the armband.
Belgium-born Guinea coach Paul Put, who took outsiders Burkina Faso to the 2013 final, made three alterations, including the promotion of goalkeeper Ibrahim Kone.
Guinean Francois Kamano had an opportunity to threaten Nigeria midway through the opening half in 30 degrees celsius (86 fahrenheit) heat, but blazed a free-kick over the bar.
Nigeria's Odion Ighalo, who came off the bench to score the goal that beat Burundi, broke clear just after the half-hour mark and his angled shot flew into the side netting.
Keita was treated roughly by the Nigerians and complained to the Angolan referee after being crudely sandwiched by two opponents.
The 24-year-old Liverpool midfielder needed medical attention several times late in the first half.
Nigeria were more assertive as the second half progressed and an interception prevented a Musa pass after a great run finding the unmarked Ighalo.
Peter Etebo then stung the fingers of Kone from a free-kick that the goalkeeper parried and a defender cleared.
Coach Put decided that Keita was not sufficiently fit to last a full match in the heat and replaced him with Lass Bangoura on 71 minutes.
Two minutes later Nigeria took a deserved lead as Omeruo, one of three survivors from the 2013 Cup of Nations-winning team in the squad, nodded a corner past Kone.