Pakistan have won the fourth one-day international against South Africa by three wickets to take the series to a 2-2 draw.
The visitors were given a target of 235 runs following a fightback from the Proteas, who lost two wickets from the opening two balls.
Pakistan also suffered an early wobble when Mohammed Hafeez was dismissed in controversial circumstances when the batsman was taken out for obstructing the field.
Hafeez ran for a quick single when a throw to the stumps from the wicketkeeper hit the batsman's legs. Following plenty of deliberation, field umpire Billy Bowden sent Hafeez off the field.
Despite the blow, Imran Farhat managed to remain in control by surpassing a half-century to rack up 93 before getting dismissed by Dale Steyn.
Misbah-ul-Haq pushed up Pakistan's runs by scoring 80 until Robin Petersen claimed the wicket with a throw, which forced the batsman to hit towards the hands of Farhaan Behardien.
Shoaib Malik (19) and Saeed Ajmal (5) finished the innings unbeaten.