Heinrich Klaasen's crucial 46 helped South Africa secure a tense four-run victory over Bangladesh, putting them on the verge of…