Rory McIlroy will start the final round of the Abu Dhabi Championship three shots behind Scottish leader Craig Lee after receiving a two-stroke penalty.
McIlroy thought he had carded a four-under 68 in the third round to be a shot off the lead and one ahead of Open champion Phil Mickelson, who shot 63.
But he was penalised for having one foot on a spectator walkway while dropping his ball on the second hole.
"There are some stupid rules in golf and this is one of them," said McIlroy.
McIlroy was only informed of the possible infringement after finishing his round, though before he had signed his card.
The former world number one accompanied European Tour chief referee John Paramor to the scene of the incident in an attempt to resolve the issue.
After looking at the area from which McIlroy had played his shot, it was determined that his left foot would have been on the white line marking the crossing.
That meant he had not taken full relief and a two-shot penalty was applied to his score, turning a par into a double bogey and a 68 into a 70.
"I am going to go and hit the gym so hard," McIlroy said. "I am going to run myself into the ground to try to get some of the frustration out."
He now finds himself a shot behind Mickelson, who stormed into contention with a nine-under-par round having only made the cut by one shot.
India's Gaganjeet Bhullar hit 66 to lie level with Mickelson on the 10-under-par mark.
McIlroy's fellow Northern Irishman Michael Hoey is on eight under par after a 68 on Saturday.