Bangladesh moved to 3-154 at tea on Thursday’s first day of the second test against South Africa.
Bangladesh captain Mushfiqur Rahim, who had won the toss, was unbeaten on 42 with Mahmudullah not out 25.
Rahim led from the front after South African part-time offspinner JP Duminy dealt a double blow just after the lunch session, dismissing Mominul Haque (40) and Imrul Kayes (30) in two overs.
In that time, the home side slumped from 1-81 to 3-86.
Mominul was undone by the extra bounce as he attempted a late cut while Kayes misjudged the length to be hit in front.
They rescued the side with a 69-run partnership after South African fast bowler Dale Steyn reached the 400-wicket milestone, having removed Tamim Iqbal on six leave Bangladesh at 1-12.
Mominul hit six fours in his 87 balls while Kayes sent the ball three times across the boundary rope.
Rahim and Mahmudullah combined for an unbeaten 68 runs to frustrate the South African bowlers.
Rahim closed in on his first half-century after 11 innings, hitting six fours in a 72-ball 42.
Duminy has figures of 2-7 from four overs while Steyn has claimed 1-24.