Avizara Soloniaina put the Malagasy in front early in the second period, but Sinenjongo Mkiva equalised late on to seal a precious point for the South Africans.
South Africa now face a final clash against Lesotho on Tuesday where victory should seal their passage to the semifinals.
The pools are decided on a head-to-head basis, but as South Africa and Madagascar drew their match, the two will have to be separated by goal-difference.
South Africa are on +5, with Madagascar on +3, though they have potentially the easier final game against fellow islanders Mauritius.
Should both teams win they could yet each advance as group winners and the best runners-up.
Amajita fell behind on 56 minutes when they failed to defend a free-kick and Soloniaina netted to put the islanders in front.
South Africa found an equaliser on 79 minutes though as Mkiva netted with 11 minutes remaining, his second of the tournament after he also netted against Mauritius.
The Mauritians and Lesotho played to an exciting 2-2 draw in the other game in Group B, with the islanders grabbing as late equalizer to secure a point.
Tseliso Botsane gave Lesotho the lead on 16 minutes, but David Aristide equalised for Mauritius on 67 minutes.
Botsane grabbed his second to put Lesotho ahead again, but they could not hold onto their advantage as Steward Roussety grabbed an equaliser in injury-time.
Eswatini made it two wins from two and set up a showdown for top-spot in Group C when they beat Seychelles 1-0 in the opening game of the day.
Eswatini will now face Angola in their final pool match on Monday, with the winner advancing to the semifinals as the top team in the group. A draw will see Angola go through due to their superior goal-difference.
Wenzile Lushaba opened the scoring for Eswatini from the penalty-spot after 20 minutes, and they doubled their advantage just before halftime as Majahesibili Ndlovu netted just after Eswatini had spurned another chance from the spot.
The match against Angola at the Nkoloma Stadium on Monday means a quick turnaround for Eswatini, with the 12.45pm kick-off coming just 24 hours after they had seen off Seychelles.
In the other match in the pool, already ousted Mozambique and Seychelles will play for pride when they meet at the Sunset Stadium at the same time. Both have lost two from two and this presents them with a chance to leave Zambia with a morale-boosting win.
Group A will also conclude when there is another winner-takes-all tie between Zambia and Malawi at the Nkoloma Stadium at 3.30pm.
A draw will be enough to see Zambia advance in top spot, while defeat would put Malawi through and leave the host nation hoping they can qualify as one of the best-placed runners-up.
Zambia will be heavy favourites have scored seven goals in their two Group A matches without conceding at the other end.
General entrance tickets cost K10.00 and are valid for all matches played on the day. There is also a VIP option available for at a cost of K50.00. Tickets in both categories are on sale at Computicket in all Shoprite outlets nationwide.
Seychelles 0 Eswatini 2 (Lushaba 20’pen, Ndlovu 45’)
Mauritius 2 (D. Aristide 67′, Roussety 90′) Lesotho 2 (Botsane 16’, 71)
Madagascar 1 (Soloniaina 59’) South Africa 1 (Mkiva 79’)
12h45 (10.45am GMT): Angola vs Eswatini – Nkoloma Stadium
12h45 (10.45am GMT): Mozambique vs Seychelles – Sunset Stadium
3.30pm (1.30pm GMT): Zambia vs Malawi – Nkoloma Stadium
3.30pm (1.30pm GMT): Comoros Islands vs Botswana – Sunset Stadium