Rafael Nadal had to fight back from a set down to defeat Belarus qualifier Ilya Ivashka on Wednesday as the Spaniard survived an early test in his bid to win the Barcelona title for the 12th time.
The 34-year-old Nadal, who suffered a surprise quarter-final exit at the hands of Andrey Rublev in the Monte Carlo Masters quarter-finals last week, dropped the first set against the world 111 before pulling through 3-6, 6-2, 6-4.
It was Nadal's 62nd win in the tournament against just four defeats.
He next faces either Japan's Kei Nishikori, the 2014 and 2015 Barcelona champion, or Chile's Christian Garin in the quarter-finals.
Fiery Italian Fabio Fognini was defaulted from the event for verbally abusing a line judge.
The 33-year-old was trailing world number 147 Bernabe Zapata Miralles 6-0, 4-4 when he clashed with the official and was defaulted by the umpire for unsportsmanlike conduct.
Fognini is one of only a small number of players to have been defaulted from a match.
The most famous incident involved world number one Novak Djokovic who was disqualified from the 2020 US Open for hitting a line judge with a ball.
Nick Kyrgios was defaulted at the Rome tournament in 2019 after hurling a chair on to the court.
Fognini, the world number 27, is no stranger to being disqualified.
At the 2017 US Open, he was booted out of the tournament and fined $24,000 for a series of insults aimed at a female chair umpire.
Elsewhere on Wednesday, Monte Carlo champion and second seed Stefanos Tsitsipas eased past Spain's Jaume Munar 6-0, 6-2.
It was a far more comfortable afternoon for the Greek than the last time he faced Munar.
That was at the 2020 French Open where he dropped the first two sets before winning their first round tie.
Monte Carlo runner-up Rublev, seeded three, also progressed with a comfortable 6-4, 6-3 win over Italian lucky loser Federico Gaio.