Substitute Chris Hall earned League One high-flyers Oldham an FA Cup third round replay against Championship Wolves with his vital header at Molineux.
Hall, who joined the action in the 58th minute, out jumped two Wolves defenders to power a superb close-range 72nd minute header past keeper Matt Murray.
Oldham had taken the lead against Mick McCarthy's promotion chasers but they then fell behind to goals from Seyi Olofinjana and Curtis Davies.
The Latics began the game without ace marksman Chris Porter, who had to bow out of the tie because of a family bereavement.
But they stunned Wolves as they opened the scoring with a cracking goal after 18 minutes from Paul Warne. Richie Wellens caught the Wolves defence flat-footed with his quickly-taken free kick and Warne moved in to lash a low angled drive into the far corner of the net.
But Wolves kept their heads and deservedly equalised in the 34th minute when the hard-working Alofinjana notched his third goal in four games. The big Nigerian international was quick to pounce and force the ball into the back of the Oldham net after a shot from Michael McIndoe rebounded off the foot of the near post.
Then, in the 42nd minute, Wolves made it 2-1 when striker Davies opened his goal account for the club. Rohan Ricketts crossed from the right and Davies made no mistake with a marvellous glancing header passed keeper Les Pogliacomi.
After the break Davies came close to grabbing a second goal with a shot that flew into the side netting moments before Oldham broke away and Hall got in a header that went wide of the target.
Then, just 60 seconds after Hall made it 2-2, Wolves broke away and substitute Mark Davies unleashed a low shot that went inches wide of the far post.