Preston North End suffered heartbreak in the third minute of added time when a corner led to a scrambled own goal and their exit from the fifth round of the FA Cup at the hands of Portsmouth.
The Championship strugglers had looked destined for a draw, but may have even won if they had converted a 60th minute penalty.
However, Simon Whaley's spot-kick was saved by David James and Darren Carter's late own goal proved a bitter pill to swallow.
An early effort by Portsmouth was parried by Preston keeper Andy Lonergan and, at the other end, England goalkeeper David James flapped at a Carter right-wing corner.
Whaley had a shot at a defender and then he hit the rebound well wide when he should have done better after 21 minutes.
Niko Kranjcar had a shot from a tight angle from 15 yards which went wide of the keeper's right-hand post and then he had a free header straight at the keeper.
In the 37th minute, Liam Chilvers fouled Nwankwo Kanu and Sulley Muntari hit a 25-yard free-kick which was tipped over the bar for a corner.
In the second half, Glen Johnson ran through before shooting straight at the keeper and a dangerous cross by Portsmouth from the left was touched by Youl Mawene, who nearly scored an own goal but Lonergan recovered to save.
In the 60th minute, Sylvain Distin fouled Billy Jones on the right-hand side of the penalty area and the referee gave a penalty.
The French defender left his foot in and tripped the midfielder which left referee Mike Dean with little option but to award a spot-kick.
However, Whaley hit a right foot penalty virtually straight at James, who did well to block the effort and then claim the loose ball.
Preston refused to be downhearted and Chris Brown had a 20-yard shot saved, before Carter scuffed a shot which James comfortably collected.
Substitute Neil Mellor forced a great save from James when he tipped a dipping effort over the bar as the home side continued to knock at the door.
But in the third minute of added time, a Kranjcar corner caused confusion in the Preston six-yard box and Carter ended up firing the ball into his own net after first controlling on his chest and attempting to lash away a clearance.
The result was hard luck on the Lilywhites, who were worth at least a replay on the evidence of this performance.