\interfootnotelinepenalty (except setting it to infinite values) does not actually help with the layout of footnotes when using standard LaTeX. The reason is that TeX takes the next feasible breakpoint after the footnote anchor, and uses that for splitting the footnote. And it does not reconsider the footnote split for other breakpoints, though if the footnote split leaves the page quite too short, it might still pull in further lines from the main text. So an infinite penalty might change things, but rarely to the better. You probably can make do by combining it with a manually placed
\pagebreak in the footnote.
Or you use bigfoot. bigfoot indeed plays through all combinations of breakpoints and penalties, so you can work with noninfinite penalties and get a reasonably balanced result by choosing your penalties such that a break in the listing is penalized harder than in the footnote.