Grigor Dimitrov has seen off Fabio Fognini in three sets to reach the Madrid Open third round.
The 10th seed will now face Stanislas Wawrinka for a spot in the quarter-finals of the tournament.
Fognini opened up a 3-0 lead at the start of the opening set, and the volatile Italian was able to keep Dimitrov at arm's length after that to take it 6-3.
An unpredictable second set saw Dimitrov squander two break points before saving five more on his own serve. The Bulgarian then broke twice on his way to winning 6-2.
Dimitrov let a 3-0 lead in the decider slip from his grasp as Fognini mounted a comeback, but the former Wimbledon semi-finalist eventually ground his opponent down to seal his progress 3-6 6-2 7-5.