Barnsley conceded a 93rd-minute winner after Adam Jackson had scored an injury-time equaliser as they lost 2-1 to Wolverhampton Wanderers.
Home substitute Bright Enobakhare netted with ten minutes remaining from a cross by Alfred N'Diaye who then scored the winner after Jackson had smashed in his first Championship goal.
It was a third successive loss in all competitions and leaves the Reds with seven points from eight Championship matches this season. Head coach Paul Heckingbottom made five changes to the cup side that lost 1-0 at Tottenham Hotspur on Tuesday and reverted to the side that lost 3-0 at home to Aston Villa in the league.
After a very quiet first quarter of an hour, both sides had good headed chances as Diogo Jota nodded over an Ivan Cavaleiro cross then Brad Potts picked out Tom Bradshaw who headed straight at home goalkeeper John Ruddy. Cavaleiro came close again when he shot over the bar from just outside the box but then Barnsley thought they should have had a penalty when Bradshaw looked to be pushed over in the box.
Cavaleiro missed the best chance of the first half on 40 minutes when he sent a low 12-yard shot wide of the right post after being perfectly picked out by Rubén Vinagre's left-wing pull-back. Hammill had a low 25-harder easily saved by Ruddy just before the break so Barnsley went into the break having had the only two efforts on target.
Adam Davies, making his first appearance in the Barnsley goal had his first save to make five minutes after the interval when half-time substitute Barry Douglas latched onto a pass by Leo Bonatini and fired straight at Davies from eight yards out on the left of the box. The goalkeeper then easily caught a low 30-yarder from Neves midway through the first half.
Bonatini was put clean through by Jota but fired just off target when attempting to smash the ball into the top right corner from inside the box. The home goal eventually came as two substitutes combined with N'Diaye, who had been on the pitch for less than a minute, crossing from the right and Bright Enobakhare volleying back across goal into the bottom right corner.
The equaliser came after 91 minutes when the ball bounced around the home box and Jackson smashed in via a deflection. But N'Diaye won it two minutes later by turning in a left-wing cross from close range.