I have to echo paveeprinces sentiments about not being too blame. Things happen and we can all find ourselves in unusual circumstances due to a vast array or reasons and while not too blame you are however responsible for yourself. Being involved with someone who's involved with someone else may not be honouring who you are or helping you in your journey to where you want to be.
Although friends it sounds like you've both entered into a dangerous liaison that could very well lead to heartbreak. Like London said he could very well be in the same situation as you and currently in the process of navigating his way through conflicts with his personal identity and sexual orientation.
However unlike yourself he is not single which is a genuine cause for concern. Not only from a possible cross couple STI situation but one that involves a third person person, their emotions and your own guilt about feeling that like you shouldn't be messing around with him.
I know your lonely and being in this situation may seem on the surface to be helping but in a way it's also corroding your sense of self and leading to isolation rather then personal liberation. If your going to continue along this path (and you always have the choice too) you may need to sit yourself down and have a good look at what that means.
We are always here for you, as I doubt that anyone on this site hasn't felt the sting of loneliness or the allure of a no strings romance, so feel free to stay around a bit longer, get to know the people here, mix, mingle, socialise... it may be difficult being in your situation but together there few things we cant do
Hanu Fein