Britain’s Simon Yates retained the overall lead in the Giro d’Italia as Elia Viviani claimed his fourth stage win of the race on Wednesday.

Quick-Step Floors’ Viviani won the 155-kilometre stage 17 from Riva del Garda to Iseo in a rain-soaked sprint finish, with Ireland’s Sam Bennett of Bora-Hansgrohe forced to settle for second place after finding himself briefly boxed out on the final straight.

There was no change at the top of the general classification, in which Mitchelton-Scott’s Yates leads by 56 seconds from defending champion Tom Dumoulin of Team Sunweb.

Italian Domenico Pozzovivo of Bahrain-Merida is third, three minutes and 11 seconds down, putting him 39 seconds ahead of fourth-placed Chris Froome of Team Sky. Fifth-placed Frenchman Thibaut Pinot (Groupama-FDJ) is a further 29 seconds back.

Yates’ time of three hours 18 minutes and 57 seconds left him in 28th position on the day as he maintained his title bid by finishing safely among the main pack, which included nearest rivals Dumoulin, Pozzovivo, Froome and Pinot.

“There’s no easy day at the Giro. This was another hard one and it could have some impact on the coming mountain stages,” said 25-year-old race leader Yates at the finish line.

“I heard about splits in the bunch but I never knew who was caught behind. I hope everyone is tired, because I’m tired.”

Stage winner Viviani, barring a major accident, now has the maglia ciclamino in his grasp ahead of Thursday’s mountain stage between Abbiategrasso and Prato Nevoso.

The 29-year-old benefited from an expert lead-out from team-mates Zdenek Stybar and Fabio Sabatini during an almighty downpour in northern Italy to become the first Italian in 13 years to win four stages in a single Giro.

Dutchman Danny van Poppel (LottoNL-Jumbo) and Belgian Jens Debusschere (Lotto Fix All) completed the top five following a hectic finale on the shores of the Lago d’Iseo.

Viviani said: “We knew this could be a very hard stage and it was indeed.

“There were very strong breakaway riders but Bora controlled. We played a little bit with them.

“We did it right because it was the second last stage for sprinters and Bennett could have put my Maglia Ciclamino in danger.

“Once it came down to a bunch sprint, I asked my guys to lead me out.

“When Van Poppel anticipated the sprint, I knew it was too early. It was actually perfect for me. I could pass him.”