FR 2514 then IB 797 at Madrid
Bucharest → Madrid → Vienna
Timetable, Madrid time
22:35FR 2514 from Bucharest at the gate
19:55IB 797 to Vienna leaves the gate
21 h 20 apart on the timetable, overnight
IB 797 leaves 21 h 20 after FR 2514 arrives on the timetable: more than half a day, so not a connection we count.