What ifs are always interesting. This one is because it posits that Lincoln loses the election. I guess anything is possible but I have never seen any evidence that, without the taking of Mobile Bay and Atlanta, he would have lost. I know Lincoln had feelings of insecurity but there were no polls or surveys bearing on this question. The strategic position of the South was dire in the fall of 1864. Tennessee, North Alabama, North Georgia, South Louisiana, were occupied. The desertion rate in the Confederate army was increasing rapidly. By contrast, no Confederate troops were in possession of any portion of a northern state. It made no sense to change horses in the middle of the stream under these circumstances.
But assuming he lost, I do not believe slavery would have lasted much longer than it did. Lincoln would have implemented a surge to bring an end to the war before McClellan was inaugurated on March 4, 1865. Failing that, McClellan may not have been willing to fight for emancipation, but there was a large and very determined group who would have: the USCT. These men, 180,000 armed troops, could have and likely would have led a massive slave insurrection.