Also been there. I was in a three year relationship several years ago that I knew had no future. I had low self-esteem and didn't think I could find someone again, so I continued needlessly.
Talk about a mistake, we broke up, decided to simply part, no hostilities, and we still talk from time to time. Now I'm in a great relationship, and have had several others since then. That relationship was a great life lesson for me, and I won't be stuck there again.
"All is fair in love and war." - Francis Edward Smedley