DL 5250 then DL 5170 at JFK
Buffalo → New York → Toronto
Timetable, New York time
20:59DL 5250 from Buffalo at the gate
20:55DL 5170 to Toronto leaves the gate
23 h 56 apart on the timetable, overnight
DL 5170 leaves 23 h 56 after DL 5250 arrives on the timetable: more than half a day, so not a connection we count.