W6 2339 then FR 5872 at Fiumicino
Budapest → Rome → Gdansk
Timetable, Rome time
07:55W6 2339 from Budapest at the gate
06:25FR 5872 to Gdansk leaves the gate
22 h 30 apart on the timetable, overnight
FR 5872 leaves 22 h 30 after W6 2339 arrives on the timetable: more than half a day, so not a connection we count.