W6 2377 then FR 3189 at Barcelona
Budapest → Barcelona → Fes
Timetable, Barcelona time
20:05W6 2377 from Budapest at the gate
10:30FR 3189 to Fes leaves the gate
14 h 25 apart on the timetable, overnight
FR 3189 leaves 14 h 25 after W6 2377 arrives on the timetable: more than half a day, so not a connection we count.