Leckie played a full game as Pascal Gross gave Ingolstadt an early lead but the visitors, who are 14 points adrift of safety, turned the game on its head before half-time with two goals from Mario Vrancic - the second from the penalty spot.
Almog Cohen levelled things up after 68 minutes and four minutes later Markus Suttner restored Ingolstadt's advantage, which they held on to for a third straight league win.
Both sides finished the match with 10 men after Romain Bregerie and Antonio Colak were sent off in the 87th minute.
Hertha Berlin ended their losing streak and moved into fifth place with a comfortable 2-0 win over strugglers Augsburg.
Coming off the back of three successive defeats, Hertha reignited their European ambitions with two unanswered goals before half-time.
USA defender John Brooks put the hosts ahead by heading home Valentin Stocker's 12-minute cross, before the latter added his own name to the scoresheet with a close-range finish in the 37th minute.
Anything but defeat would have lifted the visitors out of the bottom three but they remain behind Mainz on goal difference.