Novak Djokovic had to come from behind to defeat Thomaz Bellucci 5-7 6-2 6-3 and reach the quarter-finals of the Italian Open.
The 27-year-old Brazilian gave the world number one trouble with his powerful serving and ground strokes, and also exhibited good foot speed early on.
Djokovic was then stunned as he went on to lose the first set 7-5 against his 68th-ranked opponent and it looked like the defending champion could suffer an upset.
Nevertheless the Serbian rallied round by breaking early in the second set before going on to get the decisive break late in the third, extending his winning streak to 18 matches.
Djokovic will next face fifth seed Kei Nishikori, who beat Viktor Troicki of Serbia 6-4 6-3 earlier in the day.