South Africa have ended the third day of the first Test match with New Zealand with a five-run lead in Dunedin.
New Zealand began the day on 177-3 and would have had ambitions to establish a sizeable lead over the Proteas, but they failed to make the most of their promising start on Thursday.
Skipper Kane Williamson hit 18 fours during a superb knock of 130, but too many of his teammates underperformed with only BJ Watling (50) and Neil Wagner (32) posting respectable totals on Friday as Keshav Maharaj recorded figures of 5-94.
The home side were eventually all out for 341 - giving them a lead of 31 runs - but despite South Africa opener Stephen Cook being dismissed by the fourth ball of the second innings, the tourists managed to reach 38-1 at the close of play.
Dean Elgar (12*) and Hashim Amla (23*) remain at the crease with South Africa holding a marginal lead heading into Saturday's three sessions.