1. He has a girlfriend, so you're not going to go out with him.
2. It's fine to chat with him.
3. You don't want his girlfriend to get the wrong idea, especially if she's also your friend, so ...
4. When you see your girlfriend, say " I was talking to [Bob, or whatever] the other day. He seems really nice."
She will be flattered, because everyone likes people to say nice things about their other half (as long as its not "hey, your boyfriend is really good in bed" LOL)