Nacer Bouhanni became the first Frenchman in three years to win a Giro d'Italia stage when he sprinted to victory in wet conditions.
The FDJ rider survived a late puncture and then held off the challenges of Trek's Giacomo Nizzolo and Giant's Tom Veelers to win stage four.
German Marcel Kittel, winner of two of the first three stages, pulled out of the race because of a fever.
Michael Matthews of Orica-GreenEdge remains in the overall lead.
"I suffered a puncture on the front wheel and had a problem with the rear wheel but my team-mates were fantastic in pulling me back towards the front of the peloton," Bouhanni said of the incident that happened 2km from the finish.
"In the last lap I slipped twice or three times but managed to stay on the bike and then I gave everything."
With the event back on Italian soil after three days in Ireland, organisers allowed the riders the luxury of a late start on a short, flat 112km stage from Giovinazzo to a tight circuit in the port of Bari.
But instead of a return to the sun, the race was again dogged by a repeat of the wet and windy conditions which had been such a feature of the opening three stages.
The riders stayed bunched during the early part and were unwilling to risk increasing the speed until the roads had dried out.
With one lap of the eight circuits to go in Bari, it was decided that the stage would be neutralised from a general classification point of view, allowing those challenging for the title to take it easy while the sprinters battled it out for the line.
After speaking with the team doctor on Tuesday morning, a decision was made for him to end his Giro debut.
"I am very disappointed about leaving after such a strong start in good condition, but I do not feel healthy and I am not in the position to start the stage in this condition," the 26-year-old said.
1. Nacer Bouhanni (Fra/FDJ) 2:22:06"
2. Giacomo Nizzolo (Ita/Trek) ST
3. Tom Veelers (Ned/Giant)
4. Roberto Ferrari (Ita/Lampre)
5. Elia Viviani (Ita/Cannondale)
6. Matteo Montaguti (Ita/AG2R)
7. Kenny Dehaes (Bel/Lotto)
8. Luka Mezgec (Slo/Giant)
9. Bert De Backer (Bel/Giant)
10. Francesco Chicchi (Ita/Neri Sottoli)
1. Michael Matthews (Aus/Orica) 12:28:43"
2. Alessandro Petacchi (Ita/Omega Pharma - Quick-Step) +8"
3. Daniel Oss (Ita/BMC Racing) +10"
4. Luke Durbridge (Aus/Orica) +14"
5. Ivan Santaromita (Ita/Orica)
6. Svein Tuft (Can/Orica)
7. Pieter Weening (Ned/Orica)
8. Cameron Meyer (Aus/Orica)
9. Rigoberto Uran (Col/Omega Pharma - Quick-Step) +19"
10. Gianluca Brambilla (Ita/Omega Pharma - Quick-Step)